Lint
parent
9f4a7fcff7
commit
e646685bc3
|
@ -32,7 +32,7 @@ export default class Load extends Command {
|
||||||
delete require.cache[`${corepath}/commands/index.js`];
|
delete require.cache[`${corepath}/commands/index.js`];
|
||||||
delete require.cache[`${corepath}/commands/${args[1]}.js`];
|
delete require.cache[`${corepath}/commands/${args[1]}.js`];
|
||||||
Object.keys(require.cache).filter((path) => path.includes(`${args[1]}_`)).forEach((path) => delete require.cache[path]);
|
Object.keys(require.cache).filter((path) => path.includes(`${args[1]}_`)).forEach((path) => delete require.cache[path]);
|
||||||
const cmdIndex = require('../commands');
|
const cmdIndex = require('.');
|
||||||
let Cmd = cmdIndex[args[1]];
|
let Cmd = cmdIndex[args[1]];
|
||||||
if (!Cmd) return message.channel.createMessage(`${this.client.stores.emojis.error} ***Could not find file***`);
|
if (!Cmd) return message.channel.createMessage(`${this.client.stores.emojis.error} ***Could not find file***`);
|
||||||
Cmd = require(`${corepath}/commands/${args[1]}`).default;
|
Cmd = require(`${corepath}/commands/${args[1]}`).default;
|
||||||
|
|
Loading…
Reference in New Issue