diff options
author | Kohei Yoshino <kohei.yoshino@gmail.com> | 2018-09-24 23:27:12 +0200 |
---|---|---|
committer | Kohei Yoshino <kohei.yoshino@gmail.com> | 2018-09-26 19:23:39 +0200 |
commit | 09dd4d3192073ba9ecc7feb8a5dfcd213affd525 (patch) | |
tree | 72431fb524edf6e92afd63237e56f229217c3257 /Bugzilla/WebService/Bug.pm | |
parent | 03d03939f90f2a258d9a4840eaa9af16fca7581f (diff) | |
download | bugzilla-09dd4d3192073ba9ecc7feb8a5dfcd213affd525.tar.gz bugzilla-09dd4d3192073ba9ecc7feb8a5dfcd213affd525.tar.xz |
Bug 1493500 - Remove all trailing whitespaces from all files
Diffstat (limited to 'Bugzilla/WebService/Bug.pm')
-rw-r--r-- | Bugzilla/WebService/Bug.pm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Bugzilla/WebService/Bug.pm b/Bugzilla/WebService/Bug.pm index feb541c2e..d247b8ffb 100644 --- a/Bugzilla/WebService/Bug.pm +++ b/Bugzilla/WebService/Bug.pm @@ -666,7 +666,7 @@ sub possible_duplicates { include_fields => Optional [ ArrayRef [Str] ], Bugzilla_api_token => Optional [Str] ]; - + ThrowCodeError( 'param_invalid', { function => 'Bug.possible_duplicates', param => 'A param' } ) if !$params_type->check($params); @@ -674,10 +674,10 @@ sub possible_duplicates { if ($params->{id}) { my $bug = Bugzilla::Bug->check({ id => $params->{id}, cache => 1 }); $summary = $bug->short_desc; - } + } elsif ($params->{summary}) { $summary = $params->{summary}; - } + } else { ThrowCodeError('param_required', { function => 'Bug.possible_duplicates', param => 'id or summary' }); @@ -701,7 +701,7 @@ sub possible_duplicates { if ($params->{id}) { @$possible_dupes = grep { $_->id != $params->{id} } @$possible_dupes; } - + my @hashes = map { $self->_bug_to_hash($_, $params) } @$possible_dupes; $self->_add_update_tokens($params, $possible_dupes, \@hashes); return { bugs => \@hashes }; |