MyBB Community Forums

Full Version: Removing moderator on forum is reseting gid
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5
(2009-07-14, 08:35 AM)labrocca Wrote: [ -> ]Now you might ask "well why is this a bug"...quite simple it's because adding someone as a forum moderator overwrites their usergroup no matter if they are in a special group or not.

It does? I added an admin as a moderator and nothing happened. If I'm reading the code correctly, it only changes the user's group if he/she isn't in group id of the default admin, mod or super mod. Wouldn't an easy fix just be if the promotion was done manually?
It won't overwrite if you are in group 3 or 4. Neither are special groups. I mean custom usergroups like a group 8 or 9.

Quote:Wouldn't an easy fix just be if the promotion was done manually?

You can't achieve that because when you add a forum moderator in admincp it effect the mybb_moderators table which is the basis of the forum moderator permissions.

The only thing you can do manually is make someone a forum moderator, then edit their profile, alter their additional group to be "moderator" and redo ther main usergroup to what it was. However if you ever decide to remove this forum moderator it will place the user into usergroup 2 and you would again need to go into their profile and make all the adjustments.

My fix basically does these changes automatically.
Adding a moderator as an additional group (and therefore hidden by default) is very bad behavior. How many bug reports would we get of users trying to figure out why, after they added a user as a moderator, that they are not showing up as a moderator?

Additional groups, should only ever be explicitly set by the administrators so they are accountable for those additional groups, not MyBB.
Yes but in the forum index the "moderators" are still listed. They are shown as a forum moderator. That's not confusing at all. If you must add some descriptive text in admincp.

"forum moderators can change their display group in their usercp"

Quote:Additional groups, should only ever be explicitly set by the administrators so they are accountable for those additional groups, not MyBB.

Main usergroup shouldn't be overwritten simply because someone is a forum moderator. And the admimistrator is EXPLICITELY setting the additional group by making the member a forum moderator. It's not an accident.
Well, that was what I meant (i think). I mean, add the mod, change the usergroup. Simple enough I'd say. I'm not rly in the mood to comprehend any posts tho.
(2009-07-14, 07:33 PM)labrocca Wrote: [ -> ]Yes but in the forum index the "moderators" are still listed. They are shown as a forum moderator. That's not confusing at all. If you must add some descriptive text in admincp.

"forum moderators can change their display group in their usercp"

Quote:Additional groups, should only ever be explicitly set by the administrators so they are accountable for those additional groups, not MyBB.

Main usergroup shouldn't be overwritten simply because someone is a forum moderator. And the administrator is EXPLICITLY setting the additional group by making the member a forum moderator. It's not an accident.
This is exactly what I mean, in an example:
say you use labrocca's MyIPN plugin (yay free advertising xD), and a member is a subscriber and has access to forum id 5 (We'll call it "The Lounge") but not forum id 6 ("Staff"), and he's doing very well on his path to being a mod, so you promote him, then, for whatever reason, another admin demotes him, thereby resetting his access to the forums to those of gid 2.
Yes Stingreay you understand the problem well. And this can go for any time that a member is in a special group and placed as a forum moderator.
MyBB *SHOULDN'T* reset BOTH groups, it should only remove or add the necessary permissions and styles. If that's done then a subscriber or other privileged member then they'll keep everything to do with that group on demote from a group with more privileges.
When MyBB removes the user as a moderator, it should only remove the moderator usergroup. Is this not how the functionality is currently working?
In this case, no. In a production environment, stuff like what we're seeing here should never happen.
Pages: 1 2 3 4 5