Skip to content

Commit

Permalink
fix: Potential error.
Browse files Browse the repository at this point in the history
  • Loading branch information
vxern committed Jun 20, 2024
1 parent 66ea759 commit e58d20d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/library/commands/handlers/purge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@ function getMessageContent(
interaction: Logos.Interaction,
message: Discord.Message,
): string | undefined {
if (message.content?.trim().length === 0 && message.embeds?.length > 0) {
if (message.content?.trim().length === 0 && (message.embeds?.length ?? 0) > 0) {
return undefined;
}

Expand Down

0 comments on commit e58d20d

Please sign in to comment.