Fix things (hopefully)

This commit is contained in:
Ecolipsy 2021-12-02 17:08:49 +01:00
parent 83906b211d
commit 98c11c51aa

View file

@ -17,7 +17,7 @@ function parseCommands(){
var rootdir = fs.readdirSync("Juustobotti/commands"); var rootdir = fs.readdirSync("Juustobotti/commands");
rootdir.forEach(categorydir => { rootdir.forEach(categorydir => {
if(!isDir("Juustobotti/commands/" + categorydir)) return; if(!isDir("Juustobotti/commands/" + categorydir)) return;
categorydir.forEach(file => { require("Juustobotti/commands/" + categorydir).forEach(file => {
if(isDir("Juustobotti/commands/" + categorydir + "/" + file)) return; if(isDir("Juustobotti/commands/" + categorydir + "/" + file)) return;
indexes.file = categorydir; indexes.file = categorydir;
cmdFiles.push(file); cmdFiles.push(file);