Hotfix client config stuff again

This commit is contained in:
Snazzah 2020-08-11 21:58:16 -05:00
parent b4aa944723
commit eee672c1ba
No known key found for this signature in database
GPG key ID: 5E71D54F3D86282E

View file

@ -1,6 +1,7 @@
const fs = require('fs');
const path = require('path');
const reload = require('require-reload')(require);
const config = require('config');
module.exports = class CommandLoader {
constructor(client, cPath) {
@ -88,7 +89,7 @@ module.exports = class CommandLoader {
* @param {Command} command
*/
async processCooldown(message, command) {
if (this.client.config.elevated.includes(message.author.id)) return true;
if (config.elevated.includes(message.author.id)) return true;
const now = Date.now() - 1;
const cooldown = command.cooldownAbs;
let userCD = await this.client.db.hget(`cooldowns:${message.author.id}`, command.name) || 0;