This commit is contained in:
Flummi 2017-11-26 15:24:05 +01:00
parent fdafc44044
commit c913e53ddb

View File

@ -10,9 +10,10 @@ const data = {
}; };
Object.keys(data).forEach(cur => { Object.keys(data).forEach(cur => {
sql.exec(`select \`data\` from \`useless\` where \`trigger\` = '${cur}' limit 1`, (err, row) => { sql.exec("select `data` from `useless` where `trigger` = ? limit 1", [cur])
data[cur] = JSON.parse(row[0].data); .then(rows => {
}); data[cur] = JSON.parse(rows[0].data);
});
}); });
module.exports = bot => { module.exports = bot => {