From ca9677ea81c6473a734f1e6258aeecbb6ef8b277 Mon Sep 17 00:00:00 2001 From: SoAJeff <24305890+SoAJeff@users.noreply.github.com> Date: Tue, 11 Nov 2025 22:03:50 -0500 Subject: [PATCH] fix: Allow ?logs [user] command to be used outside of Modmail threads When the logs command is used with a user argument, the current version of Modmail requires the command to be run in a Modmail thread. This behavior change appears to have been introduced with commit 9d4b8e3 as previous versions allowed the command to be used outside of Modmail threads. The other logs commands (closed-by, delete, key, responded, search) do not require the command to be run in a thread. The ?logs [user] command should behave the same way as it did before. --- CHANGELOG.md | 5 +++++ cogs/modmail.py | 1 - 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 83c4f1bdd4..713ec41404 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). This project mostly adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html); however, insignificant breaking changes do not guarantee a major version bump, see the reasoning [here](https://github.com/modmail-dev/modmail/issues/319). If you're a plugin developer, note the "BREAKING" section. +# v4.2.1 + +### Fixed +- `?logs [user]` can be used outside of a Modmail thread again. + # v4.2.0 Upgraded discord.py to version 2.6.3, added support for CV2. diff --git a/cogs/modmail.py b/cogs/modmail.py index d7d9d7b010..fa6c01666b 100644 --- a/cogs/modmail.py +++ b/cogs/modmail.py @@ -1200,7 +1200,6 @@ async def anonremoveuser(self, ctx, *users_arg: Union[discord.Member, discord.Ro @commands.group(invoke_without_command=True) @checks.has_permissions(PermissionLevel.SUPPORTER) - @checks.thread_only() async def logs(self, ctx, *, user: User = None): """ Get previous Modmail thread logs of a member.