Closed Bug 284272 Opened 15 years ago Closed 15 years ago

Remove derive_groups from editusers.cgi


(Bugzilla :: Administration, task)

Not set



Bugzilla 2.22


(Reporter: Wurblzap, Assigned: bugreport)




(1 file)

(In reply to bug 119485, comment #36)
> >+    $user->derive_groups(1);
>   That should never be necesary, by the way, unless you've changed the groups
> after you've created the User.

During development, testing showed that the derive_groups calls was necessary.
But that may have been caused by some other glitch, so we may be able to get rid
of the calls.
Yeah, we should be able to set the refreshed_when properly, I'd think, and that
should do it...

Actually, we shouldn't really ever have to set refreshed_when, I'd think. One
way or the other, creating a new User should do what we need it to do... a
User's permissions don't usually change significantly enough *within a page
call* that we'd need to call derive_groups outside of
Ever confirmed: true
I have done absolutely no test. I only removed something which doesn't make
sense to me. Bugzilla::User::new called two lines earlier already calls
derive_groups() when required. In all other places, we rely on groups privs to
be up-to-date. Having to call derive_groups from here means we shouldn't trust
Bugzilla::User::new ???
Attachment #192638 - Flags: review?(wurblzap)
Comment on attachment 192638 [details] [diff] [review]
untested patch, v0.1

OK, now I see the problem.

You need to fix the query below this so that it looks for groups that can be
blessed by the user OR which have a ggm entry that can be blessed by ANY of the
groups that the user is IN().  You need to rewrite that query.
Attachment #192638 - Flags: review?(wurblzap) → review-
I will let you or Marc fix it then. ;)
Depends on: 304583
Whiteboard: blocker will fix
Assignee: nobody → bugreport
Fixed by blocker.
Closed: 15 years ago
Resolution: --- → FIXED
Whiteboard: blocker will fix
Target Milestone: --- → Bugzilla 2.22
You need to log in before you can comment on or make changes to this bug.