![]() |
|
Moderator Tools no longer have any effect after upgrading to MyBB 1.8.41 - Printable Version +- MyBB Community Forums (https://community.mybb.com) +-- Forum: Development (https://community.mybb.com/forum-161.html) +--- Forum: MyBB 1.8 Development (https://community.mybb.com/forum-165.html) +---- Forum: 1.8 Bugs and Issues (https://community.mybb.com/forum-157.html) +---- Thread: Moderator Tools no longer have any effect after upgrading to MyBB 1.8.41 (/thread-246090.html) |
Moderator Tools no longer have any effect after upgrading to MyBB 1.8.41 - Goose - 2026-10-25 Since upgrading my forum to MyBB 1.8.41, my Moderator Tools no longer seem to work. I currently have two Moderator Tools configured:
When I run either tool, the confirmation window appears correctly and I can confirm that I want to perform the action. However, after confirming, I am simply redirected back to the post, and no changes are applied. I have not noticed any related errors in the MyBB error logs. The issue appears to have started after upgrading to MyBB 1.8.41. The Moderator Tools were working correctly before the upgrade. Steps to reproduce:
RE: Moderator Tools no longer have any effect after upgrading to MyBB 1.8.41 - Goose - 2026-10-25 With the help of ChatGPT, I was able to identify and fix the issue. The proposed fix is currently working on my forum, but I would appreciate feedback from the community on whether this is the correct approach and whether it could have any unintended side effects. ### Conclusion and proposed fix The issue appears to be caused by the forum validation logic in tool_forums_allowed() in inc/class_custommoderation.php introduced in 1.8.41.When a thread-level Moderator Tool is executed, no post IDs are passed, so $pids defaults to 0. The current code converts this value into array(0). The validation then attempts to retrieve a post with ID 0, fails, and returns false. As a result, the Moderator Tool is aborted without performing any action.**Proposed fix** In the execute() method, replace the existing parameter normalization:with:
RE: Moderator Tools no longer have any effect after upgrading to MyBB 1.8.41 - arcalys - 2026-10-25 Hi, There is an issue scoped in the next release: https://github.com/mybb/mybb/issues/5432 WIth the fix pushed by dvz in the following pull request: https://github.com/mybb/mybb/pull/5433 You current fix will work until 1.8.42 is released. |