forked from cadence/out-of-your-element
make removing single reactions work correctly
This commit is contained in:
parent
a396e6f596
commit
6dcf3a383a
7 changed files with 67 additions and 30 deletions
|
@ -24,7 +24,8 @@ async function removeReaction(event) {
|
|||
const hash = utils.getEventIDHash(event.redacts)
|
||||
const row = from("reaction").join("message_channel", "message_id").select("channel_id", "message_id", "encoded_emoji").and("WHERE hashed_event_id = ?").get(hash)
|
||||
if (!row) return
|
||||
return discord.snow.channel.deleteReactionSelf(row.channel_id, row.message_id, row.encoded_emoji)
|
||||
await discord.snow.channel.deleteReactionSelf(row.channel_id, row.message_id, row.encoded_emoji)
|
||||
db.prepare("DELETE FROM reaction WHERE hashed_event_id = ?").run(hash)
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue