Commit 1c6ccf6 1 parent ee9ad0d commit 1c6ccf6 Copy full SHA for 1c6ccf6
File tree 1 file changed +6
-4
lines changed
apps/api/src/worker/notificator
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -4,8 +4,8 @@ import { SubscribeModel } from '../../models/Subscribe'
4
4
import { getCurrPerformance } from '../../routes/performance.current/service'
5
5
import { checkInterval } from '../utils/checkInterval'
6
6
import { logger } from '../utils/logger'
7
+ import { bot } from './bot'
7
8
import { INTERVAL_RUN } from './config'
8
- import { bot } from "./bot" ;
9
9
10
10
let lastRunning : Date | null = null
11
11
const log = logger ( 'notificator' )
@@ -35,11 +35,13 @@ export const notificatorChecker = async (): Promise<void> => {
35
35
36
36
if ( ! subscribe . preActionsIsSuccess ) {
37
37
getCurrPerformance ( cacheData , false ) . then ( ( ) => {
38
- if ( ! bot )
39
- return
38
+ if ( ! bot ) return
40
39
subscribe . preActionsIsSuccess = true
41
40
subscribe . save ( )
42
- bot . sendMessage ( String ( subscribe . tgId ) , `Мы загрузили ваши оценки. Теперь вы будете получать уведомления!` )
41
+ bot . sendMessage (
42
+ String ( subscribe . tgId ) ,
43
+ 'Мы загрузили ваши оценки. Теперь вы будете получать уведомления!'
44
+ )
43
45
} )
44
46
continue
45
47
}
You can’t perform that action at this time.
0 commit comments