created config starting place

This commit is contained in:
Dalton
2018-12-07 20:08:07 -08:00
parent 68340be57c
commit 141653d466
2 changed files with 51 additions and 1 deletions

6
bot.js
View File

@@ -9,7 +9,11 @@ var playVolume = [];
var queueExists = false;
var channel = null;
// grab config
var bot_config = asyncSiteRequest('http://127.0.0.1/folder/bot-config.json', config_data => {return config_data;});
// available commands
// todo use config file
function availableCommands() {
console.log('availaleCommands called.');
return "Available commands: " +
@@ -19,6 +23,7 @@ function availableCommands() {
}
// help commands
// todo use config file to grab botConfig.commandHelp
function commandsHelp(requestedCommand) {
console.log('commandsHelp called.');
let commands = {
@@ -197,7 +202,6 @@ function asyncSiteRequest(url, process) {
})
.catch(error => {
sendToBotTestingChannel(error.message);
console.log(error.message);
return "";
})
}