diff --git a/Manager.js b/Manager.js index ff0723b..105b388 100644 --- a/Manager.js +++ b/Manager.js @@ -41,8 +41,9 @@ class Manager extends EventEmitter { await this.shardManager.spawn(); // G:\Documents\My programs\GBot\New GBot\api\index.cjs this.info('Shards done, booting up API...'); - const { default: APIManager } = await import('./api/index.js').catch((err) => this.error(`Import of API Manager failed.\n${err.stack}`)); - if (APIManager) { + const API = await import('./api/index.js').catch((err) => this.error(`Import of API Manager failed.\n${err.stack}`)); + if (API) { + const { default: APIManager } = API; this.apiManager = new APIManager(this); await this.apiManager.init(); this.info('API done. Manager built.'); @@ -91,6 +92,7 @@ class Manager extends EventEmitter { const { type } = message; switch (type) { case 'statsQuery': + break; // TODO: Figure out best strategy for stats querying - push/pull, prometheus, simple polling //return this.aggregateStatistics(); }