From 44af2d396f1f7da55ab78a6bf74be92e9d82e751 Mon Sep 17 00:00:00 2001 From: Dylan William Hardison Date: Thu, 15 Jun 2017 13:10:21 -0400 Subject: perltidy cleanup --- extensions/BugModal/lib/WebService.pm | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'extensions/BugModal/lib') diff --git a/extensions/BugModal/lib/WebService.pm b/extensions/BugModal/lib/WebService.pm index 33fec6bab..a7026288c 100644 --- a/extensions/BugModal/lib/WebService.pm +++ b/extensions/BugModal/lib/WebService.pm @@ -84,20 +84,21 @@ sub rest_resources { sub products { my $user = Bugzilla->user; - return { products => _name($user->get_enterable_products) } + return { products => _name($user->get_enterable_products) }; } sub components { - my ($self, $params) = @_; - if (!ref $params->{product_name}) { - untaint($params->{product_name}); + my ( $self, $params ) = @_; + if ( !ref $params->{product_name} ) { + untaint( $params->{product_name} ); } else { - ThrowCodeError('params_required',{ function => 'BugModal.components', params => ['product'] }); + ThrowCodeError( 'params_required', + { function => 'BugModal.components', params => ['product'] } ); } - my $product = Bugzilla::Product->check({ name => $params->{product_name}, cache => 1 }); - $product = Bugzilla->user->can_enter_product($product, 1); - return { components => _name($product->components) } + my $product = Bugzilla::Product->check( { name => $params->{product_name}, cache => 1 } ); + $product = Bugzilla->user->can_enter_product( $product, 1 ); + return { components => _name( $product->components ) }; } # everything we need for edit mode in a single call, returning just the fields -- cgit v1.2.3-24-g4f1b