summaryrefslogtreecommitdiffstats
path: root/extensions/Needinfo
diff options
context:
space:
mode:
authorDave Lawrence <dlawrence@mozilla.com>2013-03-12 16:52:47 +0100
committerDave Lawrence <dlawrence@mozilla.com>2013-03-12 16:52:47 +0100
commit8e7e0ebcde79e5cd357c2644933d7bba23b03f28 (patch)
tree29dbe89e4c8bf42478703d69351a98d73a503fd7 /extensions/Needinfo
parentefcae3390e5004d3375cb848492e16d7641db97b (diff)
downloadbugzilla-8e7e0ebcde79e5cd357c2644933d7bba23b03f28.tar.gz
bugzilla-8e7e0ebcde79e5cd357c2644933d7bba23b03f28.tar.xz
Bug 849024: Adding a comment to a bug causes an internal error
r=glob
Diffstat (limited to 'extensions/Needinfo')
-rw-r--r--extensions/Needinfo/Extension.pm10
1 files changed, 7 insertions, 3 deletions
diff --git a/extensions/Needinfo/Extension.pm b/extensions/Needinfo/Extension.pm
index eb4b92c85..255e08098 100644
--- a/extensions/Needinfo/Extension.pm
+++ b/extensions/Needinfo/Extension.pm
@@ -112,9 +112,13 @@ sub bug_start_of_update {
# Find out if the requestee has already been used and skip if so
my $requestee_found;
foreach my $flag (@{ $type->{flags} }) {
- next if $flag->requestee->login ne $needinfo_flag->{requestee};
- $requestee_found = 1;
- last;
+ if ((!$flag->requestee && !exists $needinfo_flag->{requestee})
+ || ($flag->requestee && exists $needinfo_flag->{requestee}
+ && $flag->requestee->login eq $needinfo_flag->{requestee}))
+ {
+ $requestee_found = 1;
+ last;
+ }
}
next if $requestee_found;