mirror of
https://github.com/ArthurDanjou/artdanj-api.git
synced 2026-01-21 23:40:26 +01:00
Lint and update
This commit is contained in:
13
app/Tasks/SongsTask.ts
Normal file
13
app/Tasks/SongsTask.ts
Normal file
@@ -0,0 +1,13 @@
|
||||
import Logger from '@ioc:Adonis/Core/Logger'
|
||||
|
||||
const MS = 1000
|
||||
|
||||
export async function getCurrentPlayingMusic(): Promise<void> {
|
||||
// Fetch from deezer
|
||||
}
|
||||
|
||||
export async function Activate(): Promise<void> {
|
||||
Logger.info(`Starting task runner for watching deezer current playing [${MS} ms]`)
|
||||
await getCurrentPlayingMusic()
|
||||
setInterval(getCurrentPlayingMusic, MS)
|
||||
}
|
||||
Reference in New Issue
Block a user