A quick summary of the problem:
So I have followed the guide on setting the bot up, but when I attempt to run it with node main.js I get this error:
It reads:
TypeError: db.table is not a constructor
at new EconomyManager (C:\Users\sammy\Desktop\KRPSBot\2.0.5\node_modules\[4mquick.eco[24m\src\EconomyManager.js:18:24)
at Object.<anonymous> (C:\Users\sammy\Desktop\KRPSBot\2.0.5\commands\balance.js:3:13)
[90m at Module._compile (internal/modules/cjs/loader.js:1133:30)[39m
[90m at Object.Module._extensions..js (internal/modules/cjs/loader.js:1153:10)[39m
[90m at Module.load (internal/modules/cjs/loader.js:977:32)[39m
[90m at Function.Module._load (internal/modules/cjs/loader.js:877:14)[39m
[90m at Module.require (internal/modules/cjs/loader.js:1019:19)[39m
[90m at require (internal/modules/cjs/helpers.js:77:18)[39m
at Object.<anonymous> (C:\Users\sammy\Desktop\KRPSBot\2.0.5\main.js:15:18)
[90m at Module._compile (internal/modules/cjs/loader.js:1133:30)[39m
Expected outcome:
That this wouldn't happen and the program would continue as normal.
Extra comments:
I think the issue resides in the EconomyManager.js (line 18) where it says if (name) db = new db.table(name.replace(/ +/g, ""));
A quick summary of the problem: So I have followed the guide on setting the bot up, but when I attempt to run it with
node main.js
I get this error:It reads:
Expected outcome: That this wouldn't happen and the program would continue as normal.
Extra comments: I think the issue resides in the
EconomyManager.js
(line 18) where it saysif (name) db = new db.table(name.replace(/ +/g, ""));