prevent poll close if event is less than 24h old
All checks were successful
Build a docker image for node-jellyfin-role-bot / build-docker-image (push) Successful in 1m15s
All checks were successful
Build a docker image for node-jellyfin-role-bot / build-docker-image (push) Successful in 1m15s
This commit is contained in:
@ -75,7 +75,7 @@ export class ExtendedClient extends Client {
|
||||
this.cacheUsers(guilds)
|
||||
await this.cacheAnnouncementServer(guilds)
|
||||
this.startAnnouncementRoleBackgroundTask(guilds)
|
||||
this.startPollCloceBackgroundTasks()
|
||||
this.startPollCloseBackgroundTasks()
|
||||
})
|
||||
} catch (error) {
|
||||
logger.info(`Error refreshing slash commands: ${error}`)
|
||||
@ -173,7 +173,7 @@ export class ExtendedClient extends Client {
|
||||
task.stop()
|
||||
}
|
||||
|
||||
private async startPollCloceBackgroundTasks() {
|
||||
private async startPollCloseBackgroundTasks() {
|
||||
for(const guild of this.guilds.cache) {
|
||||
this.pollCloseBackgroundTasks.set(guild[1].id, schedule("0 * * * * *", () => checkForPollsToClose(guild[1])))
|
||||
}
|
||||
|
Reference in New Issue
Block a user