You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
main
${ noResults }
23 lines
581 B
TypeScript
23 lines
581 B
TypeScript
import { GeoIP } from '@server/helpers/geo-ip.js'
|
|||
import { SCHEDULER_INTERVALS_MS } from '../../initializers/constants.js'
|
|||
import { AbstractScheduler } from './abstract-scheduler.js'
|
|||
|
|||
export class GeoIPUpdateScheduler extends AbstractScheduler {
|
|||
|
|||
private static instance: AbstractScheduler
|
|||
|
|||
protected schedulerIntervalMs = SCHEDULER_INTERVALS_MS.GEO_IP_UPDATE
|
|||
|
|||
private constructor () {
|
|||
super()
|
|||
}
|
|||
|
|||
protected internalExecute () {
|
|||
return GeoIP.Instance.updateDatabases()
|
|||
}
|
|||
|
|||
static get Instance () {
|
|||
return this.instance || (this.instance = new this())
|
|||
}
|
|||
}
|