Skip to content
Snippets Groups Projects
Commit 5430d035 authored by Reviath's avatar Reviath
Browse files

If config file is not edited, it will give error.

parent 35c60aa6
No related branches found
No related tags found
No related merge requests found
const config = require('../config.json');
module.exports = {
ready: (client) => {
if (config.token == "TOKEN") {
console.warn(`You need to edit config file before running.`);
process.exit(1);
};
client.login(config.token).catch(e => {
console.warn(`An error occurred while connecting to Discord ${e}`);
process.exit(1);
......
......@@ -4,7 +4,8 @@
"description": "",
"main": "main.js",
"scripts": {
"start": "node main.js"
"start": "node main.js",
"test": "node main.js"
},
"repository": {
"type": "git",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment