Skip to content

Commit

Permalink
fix: reactions in the channel archiver command (#308)
Browse files Browse the repository at this point in the history
Co-authored-by: Almeida <[email protected]>
  • Loading branch information
BanTheNons and almeidx authored Dec 28, 2023
1 parent b881245 commit d09e056
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ export const ArchiveChannelCmd = channelArchiverCmd({
}
}

if (message.reactions && Object.keys(message.reactions).length > 0) {
if (message.reactions.cache.size > 0) {
const reactionCounts: string[] = [];
for (const [emoji, info] of Object.entries(message.reactions)) {
for (const [emoji, info] of message.reactions.cache) {
reactionCounts.push(`${info.count}x ${emoji}`);
}
content += `\n-- Reactions: ${reactionCounts.join(", ")}`;
Expand Down

0 comments on commit d09e056

Please sign in to comment.