diff options
author | Frédéric Buclin <LpSolit@netscape.net> | 2017-04-19 19:30:03 +0200 |
---|---|---|
committer | Frédéric Buclin <LpSolit@netscape.net> | 2017-04-19 19:30:03 +0200 |
commit | cf3fa62685f06f0325ef6cd0a700c278deba029f (patch) | |
tree | e2cd2b12aa455fbc0173455b16851e27e9e353d9 /Bugzilla/User.pm | |
parent | b177f09048eb2da61fe0dae35e46df66d9f34fbb (diff) | |
download | bugs-cf3fa62685f06f0325ef6cd0a700c278deba029f.tar bugs-cf3fa62685f06f0325ef6cd0a700c278deba029f.tar.gz bugs-cf3fa62685f06f0325ef6cd0a700c278deba029f.tar.bz2 bugs-cf3fa62685f06f0325ef6cd0a700c278deba029f.tar.xz bugs-cf3fa62685f06f0325ef6cd0a700c278deba029f.zip |
Do not email global watchers if the single change is about the CC list (mga#13379)
Diffstat (limited to 'Bugzilla/User.pm')
-rw-r--r-- | Bugzilla/User.pm | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Bugzilla/User.pm b/Bugzilla/User.pm index 77e6cebb0..1768d7c48 100644 --- a/Bugzilla/User.pm +++ b/Bugzilla/User.pm @@ -2132,10 +2132,16 @@ sub wants_mail { $relationship = REL_ANY; } + my $wants_mail; + Bugzilla::Hook::process('user_wants_mail', { events => $events, + relationship => $relationship, + wants_mail => \$wants_mail }); + return $wants_mail if defined $wants_mail; + # Skip DB query if relationship is explicit return 1 if $relationship == REL_GLOBAL_WATCHER; - my $wants_mail = grep { $self->mail_settings->{$relationship}{$_} } @$events; + $wants_mail = grep { $self->mail_settings->{$relationship}{$_} } @$events; return $wants_mail ? 1 : 0; } |