diff options
| author | 2022-11-25 23:21:44 +0000 | |
|---|---|---|
| committer | 2022-11-25 23:23:49 +0000 | |
| commit | e50896badaf8308df1e77c9d1df53073f7995ad0 (patch) | |
| tree | 54933826c772cf10a00bcfdc86eb69a4d1949a6e | |
| parent | Merge pull request #2318 from python-discord/help-channel-rewrite (diff) | |
Send DM message to help post opener sooner in the process
This is to give Discord time to make the thread actually avaiulable to be posted in for the send_opened_post_message call
Closes #2334 Closes BOT-3AW
| -rw-r--r-- | bot/exts/help_channels/_channel.py | 3 | 
1 files changed, 2 insertions, 1 deletions
| diff --git a/bot/exts/help_channels/_channel.py b/bot/exts/help_channels/_channel.py index a191e1ed7..cc3d831b0 100644 --- a/bot/exts/help_channels/_channel.py +++ b/bot/exts/help_channels/_channel.py @@ -109,12 +109,13 @@ async def help_thread_opened(opened_thread: discord.Thread, *, reopen: bool = Fa          await _close_help_thread(opened_thread, _stats.ClosingReason.CLEANUP)          return +    await send_opened_post_dm(opened_thread) +      if opened_thread.starter_message:          # To cover the case where the user deletes their starter message before code execution reaches this line.          await opened_thread.starter_message.pin()      await send_opened_post_message(opened_thread) -    await send_opened_post_dm(opened_thread)      cooldown_role = opened_thread.guild.get_role(constants.Roles.help_cooldown)      await members.handle_role_change(opened_thread.owner, opened_thread.owner.add_roles, cooldown_role) | 
