Fixes in code quality

pull/36/head
Trivernis 6 years ago
parent f2ef10bf08
commit bb1d952d18

@ -157,7 +157,7 @@ exports.Servant = class {
return this.processCommand(msg, globResult, content); return this.processCommand(msg, globResult, content);
} else if (commands.length < (config.maxCmdSequenceLength || 5)) { } else if (commands.length < (config.maxCmdSequenceLength || 5)) {
let answers = []; let answers = [];
let previousCommand = (commands[0].match(/^.\w+/) || [])[0];; let previousCommand = (commands[0].match(/^.\w+/) || [])[0];
for (let i = 0; i < commands.length; i++) { for (let i = 0; i < commands.length; i++) {
answers.push(this.processCommand(msg, globResult[i], commands[i], answers.push(this.processCommand(msg, globResult[i], commands[i],
true, previousCommand)); // return function to avoid "race conditions" true, previousCommand)); // return function to avoid "race conditions"

Loading…
Cancel
Save