]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 317021 - improve description of bz_canusewhine* parameters. r=gerv.
authorMatt Selsky <selsky@columbia.edu>
Tue, 25 Nov 2014 10:31:18 +0000 (10:31 +0000)
committerGervase Markham <gerv@gerv.net>
Tue, 25 Nov 2014 10:31:18 +0000 (10:31 +0000)
Bugzilla/Install.pm

index 5a2266e36fb4069ad2a670e67c094834272953ae..d02c43d2fdbb318b59075503864f4d77b4391069 100644 (file)
@@ -135,11 +135,13 @@ use constant SYSTEM_GROUPS => (
     },
     {
         name         => 'bz_canusewhineatothers',
-        description  => 'Can configure whine reports for other users',
+        description  => 'Can configure queries and schedules for periodic'
+            . ' reports to be run and sent via email to other users and groups',
     },
     {
         name         => 'bz_canusewhines',
-        description  => 'User can configure whine reports for self',
+        description  => 'Can configure queries and schedules for periodic'
+            . ' reports to be run and sent via email to themselves',
         # inherited_by means that users in the groups listed below are
         # automatically members of bz_canusewhines.
         inherited_by => ['editbugs', 'bz_canusewhineatothers'],
@@ -217,8 +219,8 @@ sub update_system_groups {
 
     # Create most of the system groups
     foreach my $definition (SYSTEM_GROUPS) {
-        my $exists = new Bugzilla::Group({ name => $definition->{name} });
-        if (!$exists) {
+        my $group = new Bugzilla::Group({ name => $definition->{name} });
+        if (!$group) {
             $definition->{isbuggroup} = 0;
             $definition->{silently} = !$editbugs_exists;
             my $inherited_by = delete $definition->{inherited_by};
@@ -234,6 +236,10 @@ sub update_system_groups {
                 }
             }
         }
+        elsif ($group->description ne $definition->{description}) {
+            $group->set_description($definition->{description});
+            $group->update();
+        }
     }
 
     $dbh->bz_commit_transaction();