2022-05-27 14:13:46 +02:00
|
|
|
import settings from "./libs/settings.js"
|
|
|
|
import getNotifier from "./libs/getNotifier.js"
|
|
|
|
import getLogger from "./libs/logger.js"
|
|
|
|
|
|
|
|
const log = getLogger("MAIN", "blue")
|
|
|
|
|
|
|
|
log("Starting up maintenance-bot...")
|
|
|
|
|
|
|
|
log("Starting up notifiers...")
|
|
|
|
const enabledNotifiers = Object.keys(settings.notifiers).filter(notifier => settings.notifiers[notifier].enabled)
|
|
|
|
const notifiers = await Promise.all(enabledNotifiers.map(notifier => getNotifier(notifier)))
|
|
|
|
|
2022-05-27 14:48:43 +02:00
|
|
|
notifiers.forEach(notifier => notifier("Started up 'maintenance-bot'..."))
|