From 90a32225e0b850c0a120fc04879e3b9d3baadfc3 Mon Sep 17 00:00:00 2001 From: Cadence Ember Date: Wed, 20 Sep 2023 07:49:36 +1200 Subject: [PATCH] d->m reactions: fix sqlite parameter error --- d2m/actions/add-reaction.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/d2m/actions/add-reaction.js b/d2m/actions/add-reaction.js index 14a9eb7..bbce42d 100644 --- a/d2m/actions/add-reaction.js +++ b/d2m/actions/add-reaction.js @@ -34,7 +34,7 @@ async function addReaction(data) { } else { // The custom emoji is not registered. We will register it and then add it. const mxc = await file.uploadDiscordFileToMxc(file.emoji(data.emoji.id, data.emoji.animated)) - db.prepare("INSERT OR IGNORE INTO emoji (id, name, animated, mxc_url) VALUES (?, ?, ?, ?)").run(data.emoji.id, data.emoji.name, data.emoji.animated, mxc) + db.prepare("INSERT OR IGNORE INTO emoji (id, name, animated, mxc_url) VALUES (?, ?, ?, ?)").run(data.emoji.id, data.emoji.name, +!!data.emoji.animated, mxc) key = mxc // TODO: what happens if the matrix user also tries adding this reaction? the bridge bot isn't able to use that emoji... }