From 5ebfb5a645503bb4799725a7362dc3540db12417 Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Tue, 29 Mar 2022 17:35:15 +0000 Subject: [PATCH] Bug 20256: (QA follow-up) Remove duplicated sub --- Koha/Patron.pm | 24 ------------------------ t/db_dependent/Koha/Patrons.t | 2 +- 2 files changed, 1 insertion(+), 25 deletions(-) diff --git a/Koha/Patron.pm b/Koha/Patron.pm index b9a34dbed3..1ca9dfe704 100644 --- a/Koha/Patron.pm +++ b/Koha/Patron.pm @@ -1619,30 +1619,6 @@ sub can_log_into { return $can; } -=head3 libraries_where_can_see_patrons - -my $libraries = $patron-libraries_where_can_see_patrons; - -Return the list of branchcodes(!) of libraries the patron is allowed to see other patron's infos. -The branchcodes are arbitrarily returned sorted. -We are supposing here that the object is related to the logged in patron (use of C4::Context::only_my_library) - -An empty array means no restriction, the patron can see patron's infos from any libraries. - -=cut - -sub libraries_where_can_see_patrons { - my ($self) = @_; - - return $self->libraries_where_can_see_things( - { - permission => 'borrowers', - subpermission => 'view_borrower_infos_from_any_libraries', - group_feature => 'ft_hide_patron_info', - } - ); -} - =head3 libraries_where_can_see_things my $libraries = $thing-libraries_where_can_see_things; diff --git a/t/db_dependent/Koha/Patrons.t b/t/db_dependent/Koha/Patrons.t index 93cd5cdedf..9656533875 100755 --- a/t/db_dependent/Koha/Patrons.t +++ b/t/db_dependent/Koha/Patrons.t @@ -19,7 +19,7 @@ use Modern::Perl; -use Test::More tests => 44; +use Test::More tests => 45; use Test::Warn; use Test::Exception; use Test::MockModule; -- 2.30.2