Closed Jimmysit0 closed 3 years ago
What's in your config.json file? (remove the token)
{ "default_prefix": "<", "token": "my_token", "hostedBy": true
}
I didn't add const config = require('./config.json'); client.config = config;
to my index, my bad.
so where put my token if remove that problem
Same problem for me also
/home/jimmy/Fuitai/commands/giveaway/start.js:51 hostedBy: client.config.hostedBy ? message.author : null, ^
TypeError: Cannot read property 'hostedBy' of undefined at Object.run (/home/jimmy/Fuitai/commands/giveaway/start.js:51:33) at Client. (/home/jimmy/Fuitai/index.js:179:17)
at processTicksAndRejections (node:internal/process/task_queues:94:5)
start.js: const ms = require('ms');
module.exports = { name: "start", run: async (client, message, args) => {
} };