Skip to content

Commit beb73d8

Browse files
committed
Deleting messages no longer shows a false error, resolves #2910
1 parent a6ebd81 commit beb73d8

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ however, insignificant breaking changes do not guarantee a major version bump, s
3333
- Custom emojis are now supported in `confirm_thread_creation_deny`. ([GH #2916](https://github.com/kyb3r/modmail/issues/2916))
3434
- Finding linked messages in replies work now. ([GH #2920](https://github.com/kyb3r/modmail/issues/2920), [Jerrie-Aries](https://github.com/kyb3r/modmail/issues/2920#issuecomment-751530495))
3535
- Sending files in threads (non-images) now work. ([GH #2926](https://github.com/kyb3r/modmail/issues/2926))
36+
- Deleting messages no longer shows a false error. ([GH #2910](https://github.com/kyb3r/modmail/issues/2910), [Jerrie-Aries](https://github.com/kyb3r/modmail/issues/2910#issuecomment-753557313))
3637

3738
### Internal
3839

core/thread.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -650,7 +650,7 @@ async def delete_message(
650650
tasks = []
651651
if not isinstance(message, discord.Message):
652652
tasks += [message1.delete()]
653-
if message2 is not None:
653+
elif message2 is not None:
654654
tasks += [message2.delete()]
655655
elif message1.embeds[0].author.name.startswith("Persistent Note"):
656656
tasks += [self.bot.api.delete_note(message1.id)]

0 commit comments

Comments
 (0)