Bug 6679 - [SIGNED-OFF] fix 4 perlcritic violations in C4/Branch.pm
authorMason James <mtj@kohaaloha.com>
Tue, 26 Jun 2012 14:31:06 +0000 (02:31 +1200)
committerPaul Poulain <paul.poulain@biblibre.com>
Thu, 20 Sep 2012 10:01:37 +0000 (12:01 +0200)
Subroutine prototypes used at line 157, column 1.  See page 194 of PBP.  (Severity: 5)
Subroutine prototypes used at line 375, column 1.  See page 194 of PBP.  (Severity: 5)
Subroutine prototypes used at line 385, column 1.  See page 194 of PBP.  (Severity: 5)
Subroutine prototypes used at line 418, column 1.  See page 194 of PBP.  (Severity: 5)

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
C4/Branch.pm

index dcd4ef7..d765c99 100644 (file)
@@ -155,7 +155,7 @@ sub mybranch {
     return C4::Context->userenv->{branch} || '';
 }
 
-sub GetBranchesLoop (;$$) {  # since this is what most pages want anyway
+sub GetBranchesLoop {  # since this is what most pages want anyway
     my $branch   = @_ ? shift : mybranch();     # optional first argument is branchcode of "my branch", if preselection is wanted.
     my $onlymine = @_ ? shift : onlymine();
     my $branches = GetBranches($onlymine);
@@ -373,7 +373,7 @@ the categories were already here, and minimally used.
 =cut
 
        #TODO  manage category types.  rename possibly to 'agency domains' ? as borrowergroups are called categories.
-sub GetCategoryTypes() {
+sub GetCategoryTypes {
        return ( 'searchdomain','properties');
 }
 
@@ -383,7 +383,7 @@ $branch = GetBranch( $query, $branches );
 
 =cut
 
-sub GetBranch ($$) {
+sub GetBranch {
     my ( $query, $branches ) = @_;    # get branch for this query from branches
     my $branch = $query->param('branch');
     my %cookie = $query->cookie('userenv');
@@ -416,7 +416,7 @@ Returns a href:  keys %$branches eq (branchcode,branchname) .
 
 =cut
 
-sub GetBranchesInCategory($) {
+sub GetBranchesInCategory {
     my ($categorycode) = @_;
        my @branches;
        my $dbh = C4::Context->dbh();