Closed
Bug 505038
Opened 15 years ago
Closed 15 years ago
Use $user->is_insider instead of $user->in_group(Bugzilla->params->{'insidergroup'})
Categories
(Bugzilla :: Bugzilla-General, enhancement, P1)
Tracking
()
RESOLVED
FIXED
Bugzilla 3.6
People
(Reporter: LpSolit, Assigned: xquezme)
Details
Attachments
(3 files)
1.17 KB,
patch
|
LpSolit
:
review-
|
Details | Diff | Splinter Review |
8.71 KB,
patch
|
Details | Diff | Splinter Review | |
5.95 KB,
patch
|
LpSolit
:
review+
|
Details | Diff | Splinter Review |
Bugzilla->params->{'insidergroup'} && $user->in_group(Bugzilla->params->{'insidergroup'}) should be replaced by $user->is_insider. That's shorter, cleaner, and less prone to errors. We should fix all places in the Bugzilla code which still doesn't use it yet.
Reporter | ||
Updated•15 years ago
|
Whiteboard: [Good Intro Bug]
Updated•15 years ago
|
Priority: -- → P1
Comment 1•15 years ago
|
||
Attachment #400013 -
Flags: review?(LpSolit)
Reporter | ||
Comment 2•15 years ago
|
||
Comment on attachment 400013 [details] [diff] [review] Found one file - importxml.pl There are much more places than that. Check everywhere where 'insidergroup' appears: 3167: if (Bugzilla->params->{"insidergroup"} 3168: && !Bugzilla->user->in_group(Bugzilla->params->{'insidergroup'})) 386622 136 -rw-r----- 1 root apache 135104 aoû 6 13:42 ./Bugzilla/Bug.pm 82: [% NEXT IF c.isprivate && !user.in_group(Param("insidergroup")) %] 96: [% NEXT IF a.isprivate && !user.in_group(Param("insidergroup")) %] 395306 8 -rw-r----- 1 root apache 6236 aoû 5 14:51 ./template/en/default/bug/show.xml.tmpl 97:[% isinsider = Param("insidergroup") && user.in_group(Param("insidergroup")) %] 395482 8 -rw-r----- 1 root apache 7951 sep 5 01:38 ./template/en/default/bug/comments.html.tmpl 78: [% IF Param("insidergroup") && user.in_group(Param("insidergroup")) %] 394991 44 -rw-r----- 1 root apache 41567 aoû 5 22:47 ./template/en/default/bug/edit.html.tmpl 56: [% IF ((attachment.isprivate == 0) || (Param("insidergroup") 57: && user.in_group(Param("insidergroup")))) %] 109: [% IF (Param("insidergroup") && user.in_group(Param("insidergroup"))) %] 395326 8 -rw-r----- 1 root apache 5270 aoû 6 22:18 ./template/en/default/attachment/create.html.tmpl 515: if ( $long_desc{'isprivate'} && $exporter->in_group($params->{'insidergroup'})) { 1201: if (!$exporter->in_group($params->{'insidergroup'}) && $att->{'isprivate'}){ 360913 56 -rwxr-x--- 1 root apache 51819 sep 7 17:11 ./importxml.pl
Attachment #400013 -
Flags: review?(LpSolit) → review-
Usage of $user->in_group(Bugzilla->params->{'insidergroup'}) replaced with $user->is_insider
Attachment #410457 -
Flags: review+
Comment 4•15 years ago
|
||
Comment on attachment 410457 [details] [diff] [review] is_insider replacement patch Don't grant review to yourself on your own patches--request review from an appropriate reviewer. Also, this patch should be against HEAD, as this is an enhancement. It should not be against BUGZILLA-3_4-BRANCH.
Attachment #410457 -
Flags: review+
review+ flag was my mistake, I'm sorry. Will avoid it in the future.
Reporter | ||
Comment 7•15 years ago
|
||
Comment on attachment 410589 [details] [diff] [review] is_insider replacement patch for HEAD Don't forget to request for review when attaching a patch. I will review it.
Attachment #410589 -
Flags: review?(LpSolit)
Reporter | ||
Comment 8•15 years ago
|
||
Comment on attachment 410589 [details] [diff] [review] is_insider replacement patch for HEAD >Index: template/en/default/bug/comments.html.tmpl >+[% isinsider = user.is_insider %] This variable could as well go away and use user.is_insider where appropriate instead. This can be fixed on checkin. r=LpSolit
Attachment #410589 -
Flags: review?(LpSolit) → review+
Reporter | ||
Updated•15 years ago
|
Assignee: general → xquezme
Status: NEW → ASSIGNED
Flags: approval+
Whiteboard: [Good Intro Bug]
Target Milestone: --- → Bugzilla 3.6
Reporter | ||
Comment 9•15 years ago
|
||
Checking in importxml.pl; /cvsroot/mozilla/webtools/bugzilla/importxml.pl,v <-- importxml.pl new revision: 1.92; previous revision: 1.91 done Checking in Bugzilla/Bug.pm; /cvsroot/mozilla/webtools/bugzilla/Bugzilla/Bug.pm,v <-- Bug.pm new revision: 1.296; previous revision: 1.295 done Checking in template/en/default/attachment/create.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/en/default/attachment/create.html.tmpl,v <-- create.html.tmpl new revision: 1.44; previous revision: 1.43 done Checking in template/en/default/bug/edit.html.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/en/default/bug/edit.html.tmpl,v <-- edit.html.tmpl new revision: 1.169; previous revision: 1.168 done Checking in template/en/default/bug/show.xml.tmpl; /cvsroot/mozilla/webtools/bugzilla/template/en/default/bug/show.xml.tmpl,v <-- show.xml.tmpl new revision: 1.35; previous revision: 1.34 done
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•