error: malformed array literal

This commit is contained in:
Lamp 2018-07-14 15:17:26 -07:00
parent 9697223c22
commit bb900f1857
No known key found for this signature in database
GPG Key ID: 0F1F8704BEDE369E
1 changed files with 1 additions and 1 deletions

View File

@ -9,7 +9,7 @@ module.exports = {
var bridge = res.rows[0];
if (bridge.owner_discord_user_id != msg.author.id) return msg.reply(`You are not the owner of this bridge.`);
var _id = msg.txt(1);
await dbClient.query("UPDATE bridges SET bans = bans || $1 WHERE discord_channel_id = $2", [_id, msg.channel.id]);
await dbClient.query("UPDATE bridges SET bans = array_append(bans, $1) WHERE discord_channel_id = $2", [_id, msg.channel.id]);
await msg.reply(`OK, I'll ban anyone whose user ID equals or starts with \`${_id}\` from this room, whenever possible.`);
var client = clients.MPP[bridge.mpp_room]