summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Bug.pm
diff options
context:
space:
mode:
Diffstat (limited to 'Bugzilla/Bug.pm')
-rwxr-xr-xBugzilla/Bug.pm11
1 files changed, 9 insertions, 2 deletions
diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm
index 5244a21b3..bfd110ad0 100755
--- a/Bugzilla/Bug.pm
+++ b/Bugzilla/Bug.pm
@@ -1406,8 +1406,15 @@ sub _set_global_validator {
my ($self, $value, $field) = @_;
my $current = $self->$field;
my $privs;
- $current = $current->id if ref $current && $current->isa('Bugzilla::Object');
- $value = $value->id if ref $value && $value->isa('Bugzilla::Object');
+
+ if (ref $current && ref($current) ne 'ARRAY'
+ && $current->isa('Bugzilla::Object')) {
+ $current = $current->id ;
+ }
+ if (ref $value && ref($value) ne 'ARRAY'
+ && $value->isa('Bugzilla::Object')) {
+ $value = $value->id ;
+ }
my $can = $self->check_can_change_field($field, $current, $value, \$privs);
if (!$can) {
if ($field eq 'assigned_to' || $field eq 'qa_contact') {