diff options
Diffstat (limited to 'extensions')
-rw-r--r-- | extensions/Profanivore/Extension.pm | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/extensions/Profanivore/Extension.pm b/extensions/Profanivore/Extension.pm index fad909c39..b77c09ce3 100644 --- a/extensions/Profanivore/Extension.pm +++ b/extensions/Profanivore/Extension.pm @@ -59,20 +59,18 @@ sub mailer_before_send { my $author = $email->header("X-Bugzilla-Who"); my $recipient = $email->header("To"); - if ($author && $recipient) { + if ($author && $recipient && lc($author) ne lc($recipient)) { my $email_suffix = Bugzilla->params->{'emailsuffix'}; if ($email_suffix ne '') { $recipient =~ s/\Q$email_suffix\E$//; $author =~ s/\Q$email_suffix\E$//; } - - $author = new Bugzilla::User({ name => $author }); - $recipient = new Bugzilla::User({ name => $recipient }); - + + $author = new Bugzilla::User({ name => $author }); + if ($author && $author->id && - !$author->in_group('editbugs') && - $author->id ne $recipient->id) + !$author->in_group('editbugs')) { my $body = $email->body_str(); |