Skip to content

Commit d4c1fec

Browse files
fix(Message#editable): fix permissions check in locked threads (#9319)
fix(Message#editable): fix permissions check if channel is thread & locked Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
1 parent 79bcdfa commit d4c1fec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/discord.js/src/structures/Message.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,7 @@ class Message extends Base {
608608
if (this.channel?.isThread()) {
609609
if (this.channel.archived) return false;
610610
if (this.channel.locked) {
611-
const permissions = this.permissionsFor(this.client.user);
611+
const permissions = this.channel.permissionsFor(this.client.user);
612612
if (!permissions?.has(PermissionFlagsBits.ManageThreads, true)) return false;
613613
}
614614
}

0 commit comments

Comments
 (0)