View | Details | Raw Unified | Return to bug 17600
Collapse All | Expand All

(-)a/C4/Accounts.pm (-3 lines)
Lines 22-35 use Modern::Perl; Link Here
22
use C4::Context;
22
use C4::Context;
23
use C4::Stats;
23
use C4::Stats;
24
use C4::Members;
24
use C4::Members;
25
use C4::Log qw(logaction);
26
use Koha::Account;
25
use Koha::Account;
27
use Koha::Account::Lines;
26
use Koha::Account::Lines;
28
use Koha::Account::Offsets;
27
use Koha::Account::Offsets;
29
use Koha::Items;
28
use Koha::Items;
30
29
31
use Mojo::Util qw(deprecated);
32
use Data::Dumper qw(Dumper);
33
30
34
use vars qw(@ISA @EXPORT);
31
use vars qw(@ISA @EXPORT);
35
32
(-)a/C4/Acquisition.pm (-8 / +6 lines)
Lines 19-31 package C4::Acquisition; Link Here
19
19
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
use Carp;
22
use Carp qw( carp croak );
23
use Text::CSV_XS;
23
use Text::CSV_XS ();
24
use C4::Context;
24
use C4::Context;
25
use C4::Suggestions;
25
use C4::Suggestions qw( GetSuggestionFromBiblionumber ModSuggestion );
26
use C4::Biblio qw( GetMarcFromKohaField GetMarcStructure IsMarcStructureInternal );
26
use C4::Biblio qw( GetMarcFromKohaField GetMarcStructure IsMarcStructureInternal );
27
use C4::Contract;
27
use C4::Contract qw( GetContract );
28
use C4::Log qw(logaction);
28
use C4::Log qw( logaction );
29
use C4::Templates qw(gettemplate);
29
use C4::Templates qw(gettemplate);
30
use Koha::DateUtils qw( dt_from_string output_pref );
30
use Koha::DateUtils qw( dt_from_string output_pref );
31
use Koha::Acquisition::Baskets;
31
use Koha::Acquisition::Baskets;
Lines 42-51 use Koha::Patrons; Link Here
42
use C4::Koha qw( GetVariationsOfISBN );
42
use C4::Koha qw( GetVariationsOfISBN );
43
43
44
use MARC::Field;
44
use MARC::Field;
45
use MARC::Record;
45
use JSON qw( to_json );
46
use JSON qw(to_json);
47
46
48
use Time::localtime;
49
47
50
use vars qw(@ISA @EXPORT);
48
use vars qw(@ISA @EXPORT);
51
49
(-)a/C4/Auth.pm (-11 / +8 lines)
Lines 19-52 package C4::Auth; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use Carp qw/croak/;
22
use Carp qw( croak );
23
23
24
use Digest::MD5 qw(md5_base64);
24
use Digest::MD5 qw( md5_base64 );
25
use JSON qw/encode_json/;
26
use URI::Escape;
27
use CGI::Session;
25
use CGI::Session;
28
26
29
use C4::Context;
27
use C4::Context;
30
use C4::Templates;    # to get the template
28
use C4::Templates;    # to get the template
31
use C4::Languages qw( getlanguage );
29
use C4::Languages ();
32
use C4::Search::History;
30
use C4::Search::History;
33
use Koha;
31
use Koha;
34
use Koha::Caches;
32
use Koha::Caches;
35
use Koha::AuthUtils qw( get_script_name hash_password );
33
use Koha::AuthUtils qw( get_script_name hash_password );
36
use Koha::Checkouts;
34
use Koha::Checkouts;
37
use Koha::DateUtils qw(dt_from_string);
35
use Koha::DateUtils qw( dt_from_string );
38
use Koha::Library::Groups;
36
use Koha::Library::Groups;
39
use Koha::Libraries;
37
use Koha::Libraries;
40
use Koha::Cash::Registers;
38
use Koha::Cash::Registers;
41
use Koha::Desks;
39
use Koha::Desks;
42
use Koha::Patrons;
40
use Koha::Patrons;
43
use Koha::Patron::Consents;
41
use Koha::Patron::Consents;
44
use POSIX qw/strftime/;
42
use List::MoreUtils qw( any );
45
use List::MoreUtils qw/ any /;
43
use Encode ();
46
use Encode qw( encode is_utf8);
47
use C4::Auth_with_shibboleth qw( shib_ok get_login_shib login_shib_url logout_shib checkpw_shib );
44
use C4::Auth_with_shibboleth qw( shib_ok get_login_shib login_shib_url logout_shib checkpw_shib );
48
use Net::CIDR;
45
use Net::CIDR ();
49
use C4::Log qw/logaction/;
46
use C4::Log qw( logaction );
50
47
51
# use utf8;
48
# use utf8;
52
use vars qw($debug $ldap $cas $caslogout);
49
use vars qw($debug $ldap $cas $caslogout);
(-)a/C4/Auth_with_cas.pm (-2 / +1 lines)
Lines 24-31 use C4::Context; Link Here
24
use Koha::AuthUtils qw( get_script_name );
24
use Koha::AuthUtils qw( get_script_name );
25
use Authen::CAS::Client;
25
use Authen::CAS::Client;
26
use CGI qw ( -utf8 );
26
use CGI qw ( -utf8 );
27
use FindBin;
27
use YAML::XS ();
28
use YAML::XS;
29
28
30
29
31
use vars qw($debug);
30
use vars qw($debug);
(-)a/C4/Auth_with_ldap.pm (-3 / +2 lines)
Lines 18-31 package C4::Auth_with_ldap; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Carp;
21
use Carp qw( croak );
22
22
23
use C4::Context;
23
use C4::Context;
24
use C4::Members::Messaging;
24
use C4::Members::Messaging;
25
use C4::Auth qw( checkpw checkpw_internal );
25
use C4::Auth qw( checkpw_internal );
26
use Koha::Patrons;
26
use Koha::Patrons;
27
use Koha::AuthUtils qw( hash_password );
27
use Koha::AuthUtils qw( hash_password );
28
use List::MoreUtils qw( any );
29
use Net::LDAP;
28
use Net::LDAP;
30
use Net::LDAP::Filter;
29
use Net::LDAP::Filter;
31
30
(-)a/C4/Auth_with_shibboleth.pm (-3 / +2 lines)
Lines 24-32 use Koha::AuthUtils qw( get_script_name ); Link Here
24
use Koha::Database;
24
use Koha::Database;
25
use Koha::Patrons;
25
use Koha::Patrons;
26
use C4::Members::Messaging;
26
use C4::Members::Messaging;
27
use Carp;
27
use Carp qw( carp );
28
use CGI;
28
use List::MoreUtils qw( any );
29
use List::MoreUtils qw(any);
30
29
31
use vars qw($debug);
30
use vars qw($debug);
32
our (@ISA, @EXPORT_OK);
31
our (@ISA, @EXPORT_OK);
(-)a/C4/AuthoritiesMarc.pm (-3 / +2 lines)
Lines 21-33 package C4::AuthoritiesMarc; Link Here
21
use strict;
21
use strict;
22
use warnings;
22
use warnings;
23
use C4::Context;
23
use C4::Context;
24
use MARC::Record;
24
use C4::Biblio qw( GetFrameworkCode GetMarcBiblio ModBiblio );
25
use C4::Biblio qw( GetMarcBiblio ModBiblio GetFrameworkCode );
26
use C4::Search qw( FindDuplicate new_record_from_zebra );
25
use C4::Search qw( FindDuplicate new_record_from_zebra );
27
use C4::AuthoritiesMarc::MARC21;
26
use C4::AuthoritiesMarc::MARC21;
28
use C4::AuthoritiesMarc::UNIMARC;
27
use C4::AuthoritiesMarc::UNIMARC;
29
use C4::Charset qw( SetUTF8Flag );
28
use C4::Charset qw( SetUTF8Flag );
30
use C4::Log;
29
use C4::Log qw( logaction );
31
use Koha::MetadataRecord::Authority;
30
use Koha::MetadataRecord::Authority;
32
use Koha::Authorities;
31
use Koha::Authorities;
33
use Koha::Authority::MergeRequests;
32
use Koha::Authority::MergeRequests;
(-)a/C4/AuthoritiesMarc/MARC21.pm (-1 lines)
Lines 18-24 package C4::AuthoritiesMarc::MARC21; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use MARC::Record;
22
21
23
=head1 NAME
22
=head1 NAME
24
23
(-)a/C4/BackgroundJob.pm (-1 / +1 lines)
Lines 21-27 package C4::BackgroundJob; Link Here
21
use Modern::Perl;
21
use Modern::Perl;
22
use C4::Context;
22
use C4::Context;
23
use C4::Auth qw( get_session );
23
use C4::Auth qw( get_session );
24
use Digest::MD5;
24
use Digest::MD5 ();
25
25
26
26
27
27
(-)a/C4/Barcodes.pm (-1 / +1 lines)
Lines 20-26 package C4::Barcodes; Link Here
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
22
23
use Carp;
23
use Carp qw( carp );
24
24
25
use C4::Context;
25
use C4::Context;
26
use C4::Barcodes::hbyymmincr;
26
use C4::Barcodes::hbyymmincr;
(-)a/C4/Barcodes/EAN13.pm (-2 / +2 lines)
Lines 22-29 use warnings; Link Here
22
22
23
use C4::Context;
23
use C4::Context;
24
24
25
use Algorithm::CheckDigits;
25
use Algorithm::CheckDigits qw( CheckDigits );
26
use Carp;
26
use Carp qw( carp );
27
27
28
use vars qw(@ISA);
28
use vars qw(@ISA);
29
29
(-)a/C4/Barcodes/annual.pm (-2 / +2 lines)
Lines 20-30 package C4::Barcodes::annual; Link Here
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
22
23
use Carp;
23
use Carp qw( carp );
24
24
25
use C4::Context;
25
use C4::Context;
26
26
27
use Koha::DateUtils qw( output_pref dt_from_string );
27
use Koha::DateUtils qw( dt_from_string output_pref );
28
28
29
use vars qw(@ISA);
29
use vars qw(@ISA);
30
use vars qw($width);
30
use vars qw($width);
(-)a/C4/Barcodes/hbyymmincr.pm (-1 / +1 lines)
Lines 19-25 package C4::Barcodes::hbyymmincr; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
22
use Carp qw( carp );
23
23
24
use C4::Context;
24
use C4::Context;
25
25
(-)a/C4/Biblio.pm (-10 / +15 lines)
Lines 76-100 BEGIN { Link Here
76
    );
76
    );
77
}
77
}
78
78
79
use Carp;
79
use Carp qw( carp );
80
use Try::Tiny;
80
use Try::Tiny qw( catch try );
81
81
82
use Encode qw( decode is_utf8 );
82
use Encode ();
83
use List::MoreUtils qw( uniq );
83
use List::MoreUtils qw( uniq );
84
use MARC::Record;
84
use MARC::Record ();
85
use MARC::File::USMARC;
85
use MARC::File::USMARC;
86
use MARC::File::XML;
86
use MARC::File::XML;
87
use POSIX qw(strftime);
87
use POSIX qw( strftime );
88
use Module::Load::Conditional qw(can_load);
88
use Module::Load::Conditional qw( can_load );
89
89
90
use C4::Koha;
90
use C4::Koha;
91
use C4::Log;    # logaction
91
use C4::Log qw( logaction );    # logaction
92
use C4::Budgets;
92
use C4::Budgets;
93
use C4::ClassSource qw( GetClassSort );
93
use C4::ClassSource qw( GetClassSort );
94
use C4::Charset qw( SetUTF8Flag SetMarcUnicodeFlag StripNonXmlChars nsb_clean );
94
use C4::Charset qw(
95
    nsb_clean
96
    SetMarcUnicodeFlag
97
    SetUTF8Flag
98
    StripNonXmlChars
99
);
95
use C4::Linker;
100
use C4::Linker;
96
use C4::OAI::Sets;
101
use C4::OAI::Sets ();
97
use C4::Items qw( GetHiddenItemnumbers GetMarcItem );
102
use C4::Items ();
98
103
99
use Koha::Logger;
104
use Koha::Logger;
100
use Koha::Caches;
105
use Koha::Caches;
(-)a/C4/Breeding.pm (-2 / +2 lines)
Lines 21-34 package C4::Breeding; Link Here
21
use strict;
21
use strict;
22
use warnings;
22
use warnings;
23
23
24
use C4::Biblio qw( AddBiblio TransformMarcToKoha TransformMarcToKohaOneField );
24
use C4::Biblio ();
25
use C4::Koha qw( GetNormalizedISBN );
25
use C4::Koha qw( GetNormalizedISBN );
26
use C4::Charset qw( MarcToUTF8Record SetUTF8Flag );
26
use C4::Charset qw( MarcToUTF8Record SetUTF8Flag );
27
use MARC::File::USMARC;
27
use MARC::File::USMARC;
28
use MARC::Field;
28
use MARC::Field;
29
use C4::ImportBatch qw( GetZ3950BatchId AddBiblioToBatch AddAuthToBatch );
29
use C4::ImportBatch qw( GetZ3950BatchId AddBiblioToBatch AddAuthToBatch );
30
use C4::AuthoritiesMarc; #GuessAuthTypeCode, FindDuplicateAuthority
30
use C4::AuthoritiesMarc; #GuessAuthTypeCode, FindDuplicateAuthority
31
use C4::Languages qw( getlanguage );
31
use C4::Languages ();
32
use Koha::Database;
32
use Koha::Database;
33
use Koha::XSLT::Base;
33
use Koha::XSLT::Base;
34
34
(-)a/C4/Budgets.pm (-1 / +1 lines)
Lines 22-28 use C4::Context; Link Here
22
use Koha::Database;
22
use Koha::Database;
23
use Koha::Patrons;
23
use Koha::Patrons;
24
use Koha::Acquisition::Invoice::Adjustments;
24
use Koha::Acquisition::Invoice::Adjustments;
25
use C4::Acquisition;
25
use C4::Acquisition ();
26
use vars qw(@ISA @EXPORT);
26
use vars qw(@ISA @EXPORT);
27
27
28
BEGIN {
28
BEGIN {
(-)a/C4/Calendar.pm (-2 / +2 lines)
Lines 19-26 use strict; Link Here
19
use warnings;
19
use warnings;
20
use vars qw(@EXPORT);
20
use vars qw(@EXPORT);
21
21
22
use Carp;
22
use Carp qw( croak );
23
use Date::Calc qw( Date_to_Days Today);
23
use Date::Calc qw( Today );
24
24
25
use C4::Context;
25
use C4::Context;
26
use Koha::Caches;
26
use Koha::Caches;
(-)a/C4/Charset.pm (-3 / +3 lines)
Lines 19-27 package C4::Charset; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use MARC::Charset qw/marc8_to_utf8/;
22
use MARC::Charset ();
23
use Text::Iconv;
23
use Text::Iconv ();
24
use Unicode::Normalize;
24
use Unicode::Normalize qw( NFC NFD );
25
use Encode qw( decode encode is_utf8 );
25
use Encode qw( decode encode is_utf8 );
26
26
27
use Koha::Logger;
27
use Koha::Logger;
(-)a/C4/Circulation.pm (-26 / +17 lines)
Lines 21-55 package C4::Circulation; Link Here
21
use Modern::Perl;
21
use Modern::Perl;
22
use DateTime;
22
use DateTime;
23
use POSIX qw( floor );
23
use POSIX qw( floor );
24
use YAML::XS;
24
use YAML::XS ();
25
use Encode;
25
use Encode ();
26
26
27
use Koha::DateUtils;
27
use Koha::DateUtils qw( dt_from_string output_pref );
28
use C4::Context;
28
use C4::Context;
29
use C4::Stats;
29
use C4::Stats qw( UpdateStats );
30
use C4::Reserves qw( CheckReserves CanItemBeReserved MoveReserve ModReserve ModReserveMinusPriority RevertWaitingStatus IsItemOnHoldAndFound IsAvailableForItemLevelRequest );
30
use C4::Reserves qw( CheckReserves CanItemBeReserved MoveReserve ModReserve ModReserveMinusPriority RevertWaitingStatus IsItemOnHoldAndFound IsAvailableForItemLevelRequest );
31
use C4::Biblio qw( UpdateTotalIssues ModZebra );
31
use C4::Biblio qw( UpdateTotalIssues );
32
use C4::Items qw( ModItemTransfer ModDateLastSeen CartToShelf );
32
use C4::Items qw( CartToShelf ModDateLastSeen ModItemTransfer );
33
use C4::Members;
33
use C4::Members ();
34
use C4::Accounts;
34
use C4::Accounts ();
35
use C4::ItemCirculationAlertPreference;
35
use C4::ItemCirculationAlertPreference;
36
use C4::Message;
36
use C4::Message;
37
use C4::Log; # logaction
37
use C4::Log qw( logaction ); # logaction
38
use C4::Overdues qw( UpdateFine get_chargeable_units CalcFine );
38
use C4::Overdues ();
39
use C4::RotatingCollections qw(GetCollectionItemBranches);
39
use C4::RotatingCollections qw(GetCollectionItemBranches);
40
use Algorithm::CheckDigits;
40
use Algorithm::CheckDigits qw( CheckDigits );
41
41
42
use Data::Dumper;
42
use Data::Dumper qw( Dumper );
43
use Koha::Account;
43
use Koha::Account;
44
use Koha::AuthorisedValues;
44
use Koha::AuthorisedValues;
45
use Koha::Biblioitems;
45
use Koha::Biblioitems;
46
use Koha::DateUtils;
46
use Koha::DateUtils qw( dt_from_string output_pref );
47
use Koha::Calendar;
47
use Koha::Calendar;
48
use Koha::Checkouts;
48
use Koha::Checkouts;
49
use Koha::Illrequests;
49
use Koha::Illrequests;
50
use Koha::Items;
50
use Koha::Items;
51
use Koha::Patrons;
51
use Koha::Patrons;
52
use Koha::Patron::Debarments;
52
use Koha::Patron::Debarments qw( DelUniqueDebarment GetDebarments );
53
use Koha::Database;
53
use Koha::Database;
54
use Koha::Libraries;
54
use Koha::Libraries;
55
use Koha::Account::Lines;
55
use Koha::Account::Lines;
Lines 62-80 use Koha::Config::SysPref; Link Here
62
use Koha::Checkouts::ReturnClaims;
62
use Koha::Checkouts::ReturnClaims;
63
use Koha::SearchEngine::Indexer;
63
use Koha::SearchEngine::Indexer;
64
use Koha::Exceptions::Checkout;
64
use Koha::Exceptions::Checkout;
65
use Carp;
65
use Carp qw( carp );
66
use List::MoreUtils qw( uniq any );
66
use List::MoreUtils qw( any );
67
use Scalar::Util qw( looks_like_number );
67
use Scalar::Util qw( looks_like_number );
68
use Try::Tiny;
68
use Date::Calc qw( Date_to_Days );
69
use Date::Calc qw(
70
  Today
71
  Today_and_Now
72
  Add_Delta_YM
73
  Add_Delta_DHMS
74
  Date_to_Days
75
  Day_of_Week
76
  Add_Delta_Days
77
);
78
our (@ISA, @EXPORT_OK);
69
our (@ISA, @EXPORT_OK);
79
BEGIN {
70
BEGIN {
80
71
(-)a/C4/ClassSortRoutine.pm (-1 lines)
Lines 20-26 package C4::ClassSortRoutine; Link Here
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
22
23
use Class::Factory::Util;
24
use C4::Context;
23
use C4::Context;
25
24
26
our (@ISA, @EXPORT_OK);
25
our (@ISA, @EXPORT_OK);
(-)a/C4/ClassSplitRoutine.pm (-1 lines)
Lines 20-26 package C4::ClassSplitRoutine; Link Here
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
require Exporter;
22
require Exporter;
23
use Class::Factory::Util;
24
23
25
use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
24
use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
26
25
(-)a/C4/Context.pm (-6 / +5 lines)
Lines 35-48 BEGIN { Link Here
35
    }
35
    }
36
};
36
};
37
37
38
use Carp;
38
use Carp qw( carp );
39
use DateTime::TimeZone;
39
use DateTime::TimeZone;
40
use Encode;
40
use Encode ();
41
use File::Spec;
41
use File::Spec ();
42
use Module::Load::Conditional qw(can_load);
43
use POSIX ();
42
use POSIX ();
44
use YAML::XS;
43
use YAML::XS ();
45
use ZOOM;
44
use ZOOM ();
46
45
47
use Koha::Caches;
46
use Koha::Caches;
48
use Koha::Config::SysPref;
47
use Koha::Config::SysPref;
(-)a/C4/CourseReserves.pm (-1 / +1 lines)
Lines 17-23 package C4::CourseReserves; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use List::MoreUtils qw(any);
20
use List::MoreUtils qw( any );
21
21
22
use C4::Context;
22
use C4::Context;
23
use C4::Circulation qw( GetOpenIssue );
23
use C4::Circulation qw( GetOpenIssue );
(-)a/C4/Creators.pm (-1 / +17 lines)
Lines 38-44 BEGIN { Link Here
38
                     get_unit_values
38
                     get_unit_values
39
                     html_table
39
                     html_table
40
    );
40
    );
41
    use C4::Creators::Lib;
41
    use C4::Creators::Lib qw(
42
    get_all_image_names
43
    get_all_layouts
44
    get_all_profiles
45
    get_all_templates
46
    get_barcode_types
47
    get_batch_summary
48
    get_card_summary
49
    get_font_types
50
    get_label_summary
51
    get_label_types
52
    get_output_formats
53
    get_table_names
54
    get_text_justification_types
55
    get_unit_values
56
    html_table
57
);
42
    use C4::Creators::PDF;
58
    use C4::Creators::PDF;
43
}
59
}
44
60
(-)a/C4/Creators/Lib.pm (-1 / +1 lines)
Lines 18-24 package C4::Creators::Lib; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Storable qw(dclone);
21
use Storable qw( dclone );
22
22
23
use autouse 'Data::Dumper' => qw(Dumper);
23
use autouse 'Data::Dumper' => qw(Dumper);
24
24
(-)a/C4/Creators/PDF.pm (-3 / +34 lines)
Lines 19-28 package C4::Creators::PDF; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use PDF::Reuse;
22
use PDF::Reuse qw(
23
    prAdd
24
    prAltJpeg
25
    prBookmark
26
    prCompress
27
    prDoc
28
    prDocDir
29
    prDocForm
30
    prEnd
31
    prExtract
32
    prField
33
    prFile
34
    prFont
35
    prFontSize
36
    prForm
37
    prGetLogBuffer
38
    prGraphState
39
    prImage
40
    prInit
41
    prInitVars
42
    prJpeg
43
    prJs
44
    prLink
45
    prLog
46
    prLogDir
47
    prMbox
48
    prPage
49
    prSinglePage
50
    prStrWidth
51
    prText
52
    prTTFont
53
);
23
use PDF::Reuse::Barcode;
54
use PDF::Reuse::Barcode;
24
use File::Temp;
55
use File::Temp ();
25
use List::Util qw/first/;
56
use List::Util qw( first );
26
57
27
58
28
sub _InitVars {
59
sub _InitVars {
(-)a/C4/Creators/Profile.pm (-2 / +1 lines)
Lines 6-13 use warnings; Link Here
6
use autouse 'Data::Dumper' => qw(Dumper);
6
use autouse 'Data::Dumper' => qw(Dumper);
7
7
8
use C4::Context;
8
use C4::Context;
9
use C4::Creators::Lib qw(get_unit_values);
9
use C4::Creators::Lib qw( get_unit_values );
10
11
10
12
sub _check_params {
11
sub _check_params {
13
    my $given_params = {};
12
    my $given_params = {};
(-)a/C4/Creators/Template.pm (-2 / +2 lines)
Lines 2-13 package C4::Creators::Template; Link Here
2
2
3
use strict;
3
use strict;
4
use warnings;
4
use warnings;
5
use POSIX qw(ceil);
5
use POSIX qw( ceil );
6
use autouse 'Data::Dumper' => qw(Dumper);
6
use autouse 'Data::Dumper' => qw(Dumper);
7
7
8
use C4::Context;
8
use C4::Context;
9
use C4::Creators::Profile;
9
use C4::Creators::Profile;
10
use C4::Creators::Lib qw(get_unit_values);
10
use C4::Creators::Lib qw( get_unit_values );
11
11
12
12
13
sub _check_params {
13
sub _check_params {
(-)a/C4/External/BakerTaylor.pm (-3 / +2 lines)
Lines 18-26 package C4::External::BakerTaylor; Link Here
18
# You should have received a copy of the GNU General Public License
18
# You should have received a copy of the GNU General Public License
19
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
# along with Koha; if not, see <http://www.gnu.org/licenses>.
20
20
21
use XML::Simple;
21
use XML::Simple ();
22
use LWP::Simple;
22
use LWP::Simple qw( get );
23
use HTTP::Request::Common;
24
23
25
use C4::Context;
24
use C4::Context;
26
25
(-)a/C4/External/OverDrive.pm (-3 / +3 lines)
Lines 21-32 use strict; Link Here
21
use warnings;
21
use warnings;
22
22
23
use Koha;
23
use Koha;
24
use JSON;
24
use JSON qw( from_json );
25
use Koha::Caches;
25
use Koha::Caches;
26
use HTTP::Request;
26
use HTTP::Request;
27
use HTTP::Request::Common;
27
use HTTP::Request::Common ();
28
use LWP::Authen::Basic;
28
use LWP::Authen::Basic;
29
use LWP::UserAgent;
29
use LWP::UserAgent ();
30
30
31
BEGIN {
31
BEGIN {
32
    require Exporter;
32
    require Exporter;
(-)a/C4/External/Syndetics.pm (-5 / +4 lines)
Lines 17-27 package C4::External::Syndetics; Link Here
17
# You should have received a copy of the GNU General Public License
17
# You should have received a copy of the GNU General Public License
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use XML::Simple;
20
use XML::Simple qw( XMLout );
21
use XML::LibXML;
21
use XML::LibXML ();
22
use LWP::Simple;
22
use LWP::Simple qw( $ua );
23
use LWP::UserAgent;
23
use LWP::UserAgent ();
24
use HTTP::Request::Common;
25
24
26
use strict;
25
use strict;
27
use warnings;
26
use warnings;
(-)a/C4/Heading.pm (-3 / +1 lines)
Lines 19-29 package C4::Heading; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use MARC::Record;
23
use MARC::Field;
22
use MARC::Field;
24
use C4::Context;
23
use C4::Context;
25
use Module::Load;
24
use Module::Load qw( load );
26
use Carp;
27
25
28
26
29
=head1 NAME
27
=head1 NAME
(-)a/C4/Heading/MARC21.pm (-1 lines)
Lines 19-25 package C4::Heading::MARC21; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use MARC::Record;
23
use MARC::Field;
22
use MARC::Field;
24
23
25
24
(-)a/C4/Heading/UNIMARC.pm (-1 lines)
Lines 20-26 package C4::Heading::UNIMARC; Link Here
20
use 5.010;
20
use 5.010;
21
use strict;
21
use strict;
22
use warnings;
22
use warnings;
23
use MARC::Record;
24
use MARC::Field;
23
use MARC::Field;
25
use C4::Context;
24
use C4::Context;
26
25
(-)a/C4/HoldsQueue.pm (-6 / +3 lines)
Lines 25-40 use warnings; Link Here
25
use C4::Context;
25
use C4::Context;
26
use C4::Search;
26
use C4::Search;
27
use C4::Circulation qw( GetTransfers GetBranchItemRule );
27
use C4::Circulation qw( GetTransfers GetBranchItemRule );
28
use C4::Members;
28
use Koha::DateUtils qw( dt_from_string );
29
use C4::Biblio;
30
use Koha::DateUtils;
31
use Koha::Items;
29
use Koha::Items;
32
use Koha::Patrons;
30
use Koha::Patrons;
33
use Koha::Libraries;
31
use Koha::Libraries;
34
32
35
use List::Util qw(shuffle);
33
use List::Util qw( shuffle );
36
use List::MoreUtils qw(any);
34
use List::MoreUtils qw( any );
37
use Data::Dumper;
38
35
39
our (@ISA, @EXPORT_OK);
36
our (@ISA, @EXPORT_OK);
40
BEGIN {
37
BEGIN {
(-)a/C4/ILSDI/Services.pm (-5 / +3 lines)
Lines 27-39 use C4::Accounts; Link Here
27
use C4::Biblio qw( GetMarcBiblio );
27
use C4::Biblio qw( GetMarcBiblio );
28
use C4::Reserves qw( CanBookBeReserved IsAvailableForItemLevelRequest CalculatePriority AddReserve CanItemBeReserved );
28
use C4::Reserves qw( CanBookBeReserved IsAvailableForItemLevelRequest CalculatePriority AddReserve CanItemBeReserved );
29
use C4::Context;
29
use C4::Context;
30
use C4::Auth qw( checkpw );
30
use C4::Auth ();
31
use XML::Simple;
32
use HTML::Entities;
33
use CGI qw ( -utf8 );
31
use CGI qw ( -utf8 );
34
use DateTime;
32
use DateTime;
35
use C4::Auth qw( checkpw );
33
use C4::Auth ();
36
use Koha::DateUtils;
34
use Koha::DateUtils qw( dt_from_string );
37
35
38
use Koha::Biblios;
36
use Koha::Biblios;
39
use Koha::Checkouts;
37
use Koha::Checkouts;
(-)a/C4/ImportBatch.pm (-4 / +11 lines)
Lines 22-32 use warnings; Link Here
22
22
23
use C4::Context;
23
use C4::Context;
24
use C4::Koha qw( GetNormalizedISBN );
24
use C4::Koha qw( GetNormalizedISBN );
25
use C4::Biblio qw( AddBiblio ModBiblio GetMarcFromKohaField GetXmlBiblio TransformMarcToKoha DelBiblio );
25
use C4::Biblio qw(
26
use C4::Items qw( ModItemFromMarc AddItemFromMarc );
26
    AddBiblio
27
use C4::Charset qw( SetUTF8Flag StripNonXmlChars MarcToUTF8Record );
27
    DelBiblio
28
    GetMarcFromKohaField
29
    GetXmlBiblio
30
    ModBiblio
31
    TransformMarcToKoha
32
);
33
use C4::Items qw( AddItemFromMarc ModItemFromMarc );
34
use C4::Charset qw( MarcToUTF8Record SetUTF8Flag StripNonXmlChars );
28
use C4::AuthoritiesMarc;
35
use C4::AuthoritiesMarc;
29
use C4::MarcModificationTemplates;
36
use C4::MarcModificationTemplates qw( ModifyRecordWithTemplate );
30
use Koha::Items;
37
use Koha::Items;
31
use Koha::Plugins::Handler;
38
use Koha::Plugins::Handler;
32
use Koha::Logger;
39
use Koha::Logger;
(-)a/C4/ImportExportFramework.pm (-5 / +5 lines)
Lines 19-30 package C4::ImportExportFramework; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use XML::LibXML;
22
use XML::LibXML ();
23
use XML::LibXML::XPathContext;
23
use XML::LibXML::XPathContext;
24
use Digest::MD5 qw();
24
use Digest::MD5 ();
25
use POSIX qw(strftime);
25
use POSIX qw( strftime );
26
use Text::CSV_XS;
26
use Text::CSV_XS ();
27
use List::MoreUtils qw(indexes);
27
use List::MoreUtils qw( indexes );
28
28
29
use C4::Context;
29
use C4::Context;
30
use Koha::Logger;
30
use Koha::Logger;
(-)a/C4/InstallAuth.pm (-3 / +1 lines)
Lines 18-33 package C4::InstallAuth; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Digest::MD5 qw(md5_base64);
22
use CGI::Session;
21
use CGI::Session;
23
use File::Spec;
22
use File::Spec ();
24
23
25
require Exporter;
24
require Exporter;
26
25
27
use C4::Context;
26
use C4::Context;
28
use C4::Output qw( output_html_with_http_headers );
27
use C4::Output qw( output_html_with_http_headers );
29
use C4::Templates;
28
use C4::Templates;
30
use C4::Koha;
31
29
32
our (@ISA, @EXPORT_OK);
30
our (@ISA, @EXPORT_OK);
33
BEGIN {
31
BEGIN {
(-)a/C4/Installer.pm (-3 / +3 lines)
Lines 19-29 package C4::Installer; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Encode qw( encode is_utf8 );
22
use Encode ();
23
use DBIx::RunSQL;
23
use DBIx::RunSQL;
24
use YAML::XS;
24
use YAML::XS ();
25
use C4::Context;
25
use C4::Context;
26
use DBI;
26
use DBI ();
27
use Koha;
27
use Koha;
28
28
29
use vars qw(@ISA @EXPORT);
29
use vars qw(@ISA @EXPORT);
(-)a/C4/Installer/PerlModules.pm (-2 / +1 lines)
Lines 3-10 package C4::Installer::PerlModules; Link Here
3
use warnings;
3
use warnings;
4
use strict;
4
use strict;
5
5
6
use File::Spec;
6
use File::Basename qw( dirname );
7
use File::Basename;
8
use Module::CPANfile;
7
use Module::CPANfile;
9
8
10
sub new {
9
sub new {
(-)a/C4/Installer/UpgradeBackup.pm (-5 / +5 lines)
Lines 18-28 package C4::Installer::UpgradeBackup; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use File::Compare qw(compare);
21
use File::Compare qw( compare );
22
use Cwd qw(cwd);
22
use Cwd qw( cwd );
23
use File::Copy;
23
use File::Copy ();
24
use File::Find;
24
use File::Find qw( find );
25
use File::Spec;
25
use File::Spec ();
26
use Exporter;
26
use Exporter;
27
27
28
use vars qw(@ISA @EXPORT );
28
use vars qw(@ISA @EXPORT );
(-)a/C4/ItemCirculationAlertPreference.pm (-1 / +1 lines)
Lines 20-26 package C4::ItemCirculationAlertPreference; Link Here
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use C4::Context;
22
use C4::Context;
23
use Carp qw(carp croak);
23
use Carp qw( carp croak );
24
24
25
use Koha::ItemTypes;
25
use Koha::ItemTypes;
26
use Koha::Patron::Categories;
26
use Koha::Patron::Categories;
(-)a/C4/Items.pm (-9 / +7 lines)
Lines 48-69 BEGIN { Link Here
48
    );
48
    );
49
}
49
}
50
50
51
use Carp;
51
use Carp qw( croak );
52
use Try::Tiny;
53
use C4::Context;
52
use C4::Context;
54
use C4::Koha;
53
use C4::Koha;
55
use C4::Biblio qw( GetFrameworkCode GetMarcFromKohaField TransformMarcToKoha _disambiguate AddBiblio GetMarcBiblio TransformKohaToMarc GetMarcStructure );
54
use C4::Biblio qw( _disambiguate GetMarcStructure TransformMarcToKoha );
56
use Koha::DateUtils;
55
use Koha::DateUtils qw( dt_from_string output_pref );
57
use MARC::Record;
56
use MARC::Record ();
58
use C4::ClassSource qw( GetClassSort GetClassSources GetClassSource );
57
use C4::ClassSource qw( GetClassSort GetClassSources GetClassSource );
59
use C4::Log;
58
use C4::Log qw( logaction );
60
use List::MoreUtils qw(any);
59
use List::MoreUtils qw( any );
61
use DateTime::Format::MySQL;
60
use DateTime::Format::MySQL;
62
use Data::Dumper; # used as part of logging item record changes, not just for
63
                  # debugging; so please don't remove this
61
                  # debugging; so please don't remove this
64
62
65
use Koha::AuthorisedValues;
63
use Koha::AuthorisedValues;
66
use Koha::DateUtils qw(dt_from_string);
64
use Koha::DateUtils qw( dt_from_string output_pref );
67
use Koha::Database;
65
use Koha::Database;
68
66
69
use Koha::Biblioitems;
67
use Koha::Biblioitems;
(-)a/C4/Koha.pm (-2 / +2 lines)
Lines 27-34 use Koha::Caches; Link Here
27
use Koha::AuthorisedValues;
27
use Koha::AuthorisedValues;
28
use Koha::Libraries;
28
use Koha::Libraries;
29
use Koha::MarcSubfieldStructures;
29
use Koha::MarcSubfieldStructures;
30
use Business::ISBN;
30
use Business::ISBN ();
31
use Business::ISSN;
31
use Business::ISSN ();
32
use autouse 'Data::cselectall_arrayref' => qw(Dumper);
32
use autouse 'Data::cselectall_arrayref' => qw(Dumper);
33
our (@ISA, @EXPORT_OK);
33
our (@ISA, @EXPORT_OK);
34
BEGIN {
34
BEGIN {
(-)a/C4/Labels/Label.pm (-4 / +3 lines)
Lines 3-12 package C4::Labels::Label; Link Here
3
use strict;
3
use strict;
4
use warnings;
4
use warnings;
5
5
6
use Text::Wrap;
6
use Text::Wrap qw( wrap );
7
use Algorithm::CheckDigits;
7
use Algorithm::CheckDigits qw( CheckDigits );
8
use Text::CSV_XS;
8
use Text::CSV_XS ();
9
use Data::Dumper;
10
use Text::Bidi qw( log2vis );
9
use Text::Bidi qw( log2vis );
11
10
12
use C4::Context;
11
use C4::Context;
(-)a/C4/Languages.pm (-2 / +2 lines)
Lines 22-29 package C4::Languages; Link Here
22
use strict;
22
use strict;
23
use warnings;
23
use warnings;
24
24
25
use Carp;
25
use Carp qw( carp );
26
use CGI;
26
use CGI ();
27
use List::MoreUtils qw( any );
27
use List::MoreUtils qw( any );
28
use C4::Context;
28
use C4::Context;
29
use Koha::Caches;
29
use Koha::Caches;
(-)a/C4/Letters.pm (-8 / +6 lines)
Lines 20-44 package C4::Letters; Link Here
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use MIME::Lite;
22
use MIME::Lite;
23
use Date::Calc qw( Add_Delta_Days );
23
use Carp qw( carp croak );
24
use Encode;
25
use Carp;
26
use Template;
24
use Template;
27
use Module::Load::Conditional qw(can_load);
25
use Module::Load::Conditional qw( can_load );
28
26
29
use Try::Tiny;
27
use Try::Tiny qw( catch try );
30
28
31
use C4::Members;
29
use C4::Members;
32
use C4::Log;
30
use C4::Log qw( logaction );
33
use C4::SMS;
31
use C4::SMS;
34
use C4::Templates;
32
use C4::Templates;
35
use Koha::DateUtils;
33
use Koha::DateUtils qw( dt_from_string output_pref );
36
use Koha::SMS::Providers;
34
use Koha::SMS::Providers;
37
35
38
use Koha::Email;
36
use Koha::Email;
39
use Koha::Notice::Messages;
37
use Koha::Notice::Messages;
40
use Koha::Notice::Templates;
38
use Koha::Notice::Templates;
41
use Koha::DateUtils qw( format_sqldatetime dt_from_string );
39
use Koha::DateUtils qw( dt_from_string output_pref );
42
use Koha::Patrons;
40
use Koha::Patrons;
43
use Koha::SMTP::Servers;
41
use Koha::SMTP::Servers;
44
use Koha::Subscriptions;
42
use Koha::Subscriptions;
(-)a/C4/Linker.pm (-1 lines)
Lines 47-53 to the preferred form. Link Here
47
47
48
use strict;
48
use strict;
49
use warnings;
49
use warnings;
50
use Carp;
51
use C4::Context;
50
use C4::Context;
52
51
53
use base qw(Class::Accessor);
52
use base qw(Class::Accessor);
(-)a/C4/Linker/Default.pm (-1 lines)
Lines 19-25 package C4::Linker::Default; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use Carp;
23
use MARC::Field;
22
use MARC::Field;
24
use C4::Heading;
23
use C4::Heading;
25
24
(-)a/C4/Linker/FirstMatch.pm (-1 lines)
Lines 19-25 package C4::Linker::FirstMatch; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use Carp;
23
use C4::Heading;
22
use C4::Heading;
24
use C4::Linker::Default;    # Use Default for flipping
23
use C4::Linker::Default;    # Use Default for flipping
25
24
(-)a/C4/Linker/LastMatch.pm (-1 lines)
Lines 19-25 package C4::Linker::LastMatch; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use Carp;
23
use C4::Heading;
22
use C4::Heading;
24
use C4::Linker::Default;    # Use Default for flipping
23
use C4::Linker::Default;    # Use Default for flipping
25
24
(-)a/C4/Log.pm (-1 lines)
Lines 27-33 use warnings; Link Here
27
use JSON qw( to_json );
27
use JSON qw( to_json );
28
28
29
use C4::Context;
29
use C4::Context;
30
use Koha::DateUtils;
31
use Koha::Logger;
30
use Koha::Logger;
32
31
33
use vars qw(@ISA @EXPORT);
32
use vars qw(@ISA @EXPORT);
(-)a/C4/MarcModificationTemplates.pm (-2 / +11 lines)
Lines 22-30 use Modern::Perl; Link Here
22
use DateTime;
22
use DateTime;
23
23
24
use C4::Context;
24
use C4::Context;
25
use Koha::SimpleMARC qw( field_exists field_equals copy_field copy_and_replace_field add_field update_field move_field delete_field );
25
use Koha::SimpleMARC qw(
26
    add_field
27
    copy_and_replace_field
28
    copy_field
29
    delete_field
30
    field_equals
31
    field_exists
32
    move_field
33
    update_field
34
);
26
use Koha::MoreUtils;
35
use Koha::MoreUtils;
27
use Koha::DateUtils;
36
use Koha::DateUtils qw( dt_from_string );
28
37
29
use vars qw(@ISA @EXPORT);
38
use vars qw(@ISA @EXPORT);
30
39
(-)a/C4/Matcher.pm (-2 / +7 lines)
Lines 19-30 package C4::Matcher; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use MARC::Record;
23
22
24
use Koha::SearchEngine;
23
use Koha::SearchEngine;
25
use Koha::SearchEngine::Search;
24
use Koha::SearchEngine::Search;
26
use Koha::SearchEngine::QueryBuilder;
25
use Koha::SearchEngine::QueryBuilder;
27
use Koha::Util::Normalize qw/legacy_default remove_spaces upper_case lower_case ISBN/;
26
use Koha::Util::Normalize qw(
27
    ISBN
28
    legacy_default
29
    lower_case
30
    remove_spaces
31
    upper_case
32
);
28
33
29
=head1 NAME
34
=head1 NAME
30
35
(-)a/C4/Members.pm (-10 / +3 lines)
Lines 22-46 package C4::Members; Link Here
22
22
23
use Modern::Perl;
23
use Modern::Perl;
24
use C4::Context;
24
use C4::Context;
25
use String::Random qw( random_string );
26
use Scalar::Util qw( looks_like_number );
25
use Scalar::Util qw( looks_like_number );
27
use Date::Calc qw/Today check_date Date_to_Days/;
26
use Date::Calc qw( check_date Date_to_Days );
28
use List::MoreUtils qw( uniq );
29
use JSON qw(to_json);
30
use C4::Log; # logaction
31
use C4::Overdues qw( checkoverdues );
27
use C4::Overdues qw( checkoverdues );
32
use C4::Reserves;
28
use C4::Reserves;
33
use C4::Accounts;
29
use C4::Accounts;
34
use C4::Biblio;
35
use C4::Letters qw( GetPreparedLetter );
30
use C4::Letters qw( GetPreparedLetter );
36
use C4::NewsChannels; #get slip news
31
use C4::NewsChannels qw( GetNewsToDisplay ); #get slip news
37
use DateTime;
32
use DateTime;
38
use Koha::Database;
33
use Koha::Database;
39
use Koha::DateUtils;
34
use Koha::DateUtils qw( dt_from_string );
40
use Koha::AuthUtils qw(hash_password);
41
use Koha::Database;
35
use Koha::Database;
42
use Koha::Holds;
36
use Koha::Holds;
43
use Koha::List::Patron;
44
use Koha::Patrons;
37
use Koha::Patrons;
45
use Koha::Patron::Categories;
38
use Koha::Patron::Categories;
46
39
(-)a/C4/Message.pm (-3 / +3 lines)
Lines 23-31 use strict; Link Here
23
use warnings;
23
use warnings;
24
use C4::Context;
24
use C4::Context;
25
use C4::Letters qw( GetPreparedLetter EnqueueLetter getletter );
25
use C4::Letters qw( GetPreparedLetter EnqueueLetter getletter );
26
use YAML::XS;
26
use YAML::XS qw( Dump );
27
use Encode;
27
use Encode ();
28
use Carp;
28
use Carp qw( carp );
29
29
30
=head1 NAME
30
=head1 NAME
31
31
(-)a/C4/NewsChannels.pm (-1 / +2 lines)
Lines 21-28 package C4::NewsChannels; Link Here
21
use Modern::Perl;
21
use Modern::Perl;
22
use C4::Context;
22
use C4::Context;
23
use Koha::DateUtils;
23
use Koha::DateUtils;
24
use C4::Log qw(logaction);
25
use Koha::News;
24
use Koha::News;
25
use Koha::DateUtils qw( dt_from_string output_pref );
26
use C4::Log qw(logaction);
26
27
27
use vars qw(@ISA @EXPORT);
28
use vars qw(@ISA @EXPORT);
28
29
(-)a/C4/Output.pm (-1 / +1 lines)
Lines 27-33 package C4::Output; Link Here
27
27
28
use Modern::Perl;
28
use Modern::Perl;
29
29
30
use URI::Escape;
30
use URI::Escape ();
31
use Scalar::Util qw( looks_like_number );
31
use Scalar::Util qw( looks_like_number );
32
32
33
use C4::Auth qw( get_template_and_user );
33
use C4::Auth qw( get_template_and_user );
(-)a/C4/Output/JSONStream.pm (-1 / +1 lines)
Lines 39-45 This module allows you to build JSON incrementally. Link Here
39
use strict;
39
use strict;
40
use warnings;
40
use warnings;
41
41
42
use JSON;
42
use JSON qw( to_json );
43
43
44
sub new {
44
sub new {
45
    my $class = shift;
45
    my $class = shift;
(-)a/C4/Overdues.pm (-7 / +5 lines)
Lines 20-38 package C4::Overdues; Link Here
20
# along with Koha; if not, see <http://www.gnu.org/licenses>.
20
# along with Koha; if not, see <http://www.gnu.org/licenses>.
21
21
22
use Modern::Perl;
22
use Modern::Perl;
23
use Date::Calc qw/Today Date_to_Days/;
23
use Date::Calc qw( Today );
24
use Date::Manip qw/UnixDate/;
24
use Date::Manip qw( UnixDate );
25
use List::MoreUtils qw( uniq );
25
use List::MoreUtils qw( uniq );
26
use POSIX qw( floor ceil );
26
use POSIX qw( ceil floor );
27
use Locale::Currency::Format 1.28;
27
use Locale::Currency::Format 1.28 qw( currency_format FMT_SYMBOL );
28
use Carp;
28
use Carp qw( carp );
29
29
30
use C4::Circulation;
30
use C4::Circulation;
31
use C4::Context;
31
use C4::Context;
32
use C4::Accounts;
32
use C4::Accounts;
33
use C4::Log; # logaction
34
use Koha::Logger;
33
use Koha::Logger;
35
use Koha::DateUtils;
36
use Koha::Account::Lines;
34
use Koha::Account::Lines;
37
use Koha::Account::Offsets;
35
use Koha::Account::Offsets;
38
use Koha::Libraries;
36
use Koha::Libraries;
(-)a/C4/Patroncards.pm (-1 / +10 lines)
Lines 16-22 BEGIN { Link Here
16
    );
16
    );
17
    use C4::Patroncards::Batch;
17
    use C4::Patroncards::Batch;
18
    use C4::Patroncards::Layout;
18
    use C4::Patroncards::Layout;
19
    use C4::Patroncards::Lib;
19
    use C4::Patroncards::Lib qw(
20
    box
21
    get_borrower_attributes
22
    get_image
23
    leading
24
    put_image
25
    rm_image
26
    text_alignment
27
    unpack_UTF8
28
);
20
    use C4::Patroncards::Patroncard;
29
    use C4::Patroncards::Patroncard;
21
    use C4::Patroncards::Profile;
30
    use C4::Patroncards::Profile;
22
    use C4::Patroncards::Template;
31
    use C4::Patroncards::Template;
(-)a/C4/Patroncards/Patroncard.pm (-3 / +7 lines)
Lines 21-32 use strict; Link Here
21
use warnings;
21
use warnings;
22
22
23
use autouse 'Data::Dumper' => qw(Dumper);
23
use autouse 'Data::Dumper' => qw(Dumper);
24
use Text::Wrap qw(wrap);
25
#use Font::TTFMetrics;
24
#use Font::TTFMetrics;
26
25
27
use C4::Creators::Lib qw(get_font_types get_unit_values);
26
use C4::Creators::Lib qw( get_unit_values );
28
use C4::Creators::PDF qw(StrWidth);
27
use C4::Creators::PDF qw(StrWidth);
29
use C4::Patroncards::Lib qw(unpack_UTF8 text_alignment leading box get_borrower_attributes);
28
use C4::Patroncards::Lib qw(
29
    box
30
    get_borrower_attributes
31
    leading
32
    text_alignment
33
);
30
34
31
=head1 NAME
35
=head1 NAME
32
36
(-)a/C4/Record.pm (-7 / +7 lines)
Lines 22-44 package C4::Record; Link Here
22
use Modern::Perl;
22
use Modern::Perl;
23
23
24
# please specify in which methods a given module is used
24
# please specify in which methods a given module is used
25
use MARC::Record; # marc2marcxml, marcxml2marc, changeEncoding
25
use MARC::Record (); # marc2marcxml, marcxml2marc, changeEncoding
26
use MARC::File::XML; # marc2marcxml, marcxml2marc, changeEncoding
26
use MARC::File::XML; # marc2marcxml, marcxml2marc, changeEncoding
27
use Biblio::EndnoteStyle;
27
use Biblio::EndnoteStyle;
28
use Unicode::Normalize; # _entity_encode
28
use Unicode::Normalize qw( NFC ); # _entity_encode
29
use C4::Biblio qw( GetXmlBiblio GetMarcBiblio EmbedItemsInMarcBiblio GetFrameworkCode );
29
use C4::Biblio qw( GetFrameworkCode GetMarcBiblio );
30
use C4::Koha; #marc2csv
30
use C4::Koha; #marc2csv
31
use C4::XSLT ();
31
use C4::XSLT ();
32
use YAML::XS; #marcrecords2csv
32
use YAML::XS (); #marcrecords2csv
33
use Encode;
33
use Encode ();
34
use Template;
34
use Template;
35
use Text::CSV::Encoded; #marc2csv
35
use Text::CSV::Encoded; #marc2csv
36
use Koha::Items;
36
use Koha::Items;
37
use Koha::SimpleMARC qw( delete_field read_field );
37
use Koha::SimpleMARC qw( read_field );
38
use Koha::XSLT::Base;
38
use Koha::XSLT::Base;
39
use Koha::CsvProfiles;
39
use Koha::CsvProfiles;
40
use Koha::AuthorisedValues;
40
use Koha::AuthorisedValues;
41
use Carp;
41
use Carp qw( carp croak );
42
42
43
use vars qw(@ISA @EXPORT);
43
use vars qw(@ISA @EXPORT);
44
44
(-)a/C4/Reports/Guided.pm (-4 / +3 lines)
Lines 19-37 package C4::Reports::Guided; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use CGI qw ( -utf8 );
21
use CGI qw ( -utf8 );
22
use Carp;
22
use Carp qw( carp croak );
23
use JSON qw( from_json );
23
use JSON qw( from_json );
24
24
25
use C4::Context;
25
use C4::Context;
26
use C4::Templates qw/themelanguage/;
26
use C4::Templates qw/themelanguage/;
27
use C4::Koha qw( GetAuthorisedValues );
27
use C4::Koha qw( GetAuthorisedValues );
28
use Koha::DateUtils;
28
use Koha::DateUtils qw( dt_from_string output_pref );
29
use Koha::Patrons;
29
use Koha::Patrons;
30
use Koha::Reports;
30
use Koha::Reports;
31
use C4::Output;
31
use C4::Output;
32
use C4::Log;
32
use C4::Log qw( logaction );
33
use Koha::Notice::Templates;
33
use Koha::Notice::Templates;
34
use C4::Letters;
35
34
36
use Koha::Logger;
35
use Koha::Logger;
37
use Koha::AuthorisedValues;
36
use Koha::AuthorisedValues;
(-)a/C4/Reserves.pm (-9 / +7 lines)
Lines 24-43 package C4::Reserves; Link Here
24
use Modern::Perl;
24
use Modern::Perl;
25
25
26
use C4::Accounts;
26
use C4::Accounts;
27
use C4::Biblio;
28
use C4::Circulation qw( CheckIfIssuedToPatron checkHighHolds GetAgeRestriction GetBranchItemRule );
27
use C4::Circulation qw( CheckIfIssuedToPatron checkHighHolds GetAgeRestriction GetBranchItemRule );
29
use C4::Context;
28
use C4::Context;
30
use C4::Items qw( get_hostitemnumbers_of ModItemTransfer CartToShelf );
29
use C4::Items qw( CartToShelf get_hostitemnumbers_of );
31
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
30
use C4::Letters ();
32
use C4::Log;
31
use C4::Log qw( logaction );
33
use C4::Members::Messaging;
32
use C4::Members::Messaging;
34
use C4::Members;
33
use C4::Members ();
35
use Koha::Account::Lines;
34
use Koha::Account::Lines;
36
use Koha::Biblios;
35
use Koha::Biblios;
37
use Koha::Calendar;
36
use Koha::Calendar;
38
use Koha::CirculationRules;
37
use Koha::CirculationRules;
39
use Koha::Database;
38
use Koha::Database;
40
use Koha::DateUtils;
39
use Koha::DateUtils qw( dt_from_string output_pref );
41
use Koha::Hold;
40
use Koha::Hold;
42
use Koha::Holds;
41
use Koha::Holds;
43
use Koha::ItemTypes;
42
use Koha::ItemTypes;
Lines 47-55 use Koha::Old::Hold; Link Here
47
use Koha::Patrons;
46
use Koha::Patrons;
48
use Koha::Plugins;
47
use Koha::Plugins;
49
48
50
use Carp;
49
use Data::Dumper qw( Dumper );
51
use Data::Dumper;
50
use List::MoreUtils qw( any );
52
use List::MoreUtils qw( firstidx any );
53
51
54
=head1 NAME
52
=head1 NAME
55
53
(-)a/C4/Ris.pm (-3 / +3 lines)
Lines 62-70 package C4::Ris; Link Here
62
62
63
use Modern::Perl;
63
use Modern::Perl;
64
64
65
use List::MoreUtils qw/uniq/;
65
use List::MoreUtils qw( uniq );
66
use YAML::XS;
66
use YAML::XS ();
67
use Encode;
67
use Encode ();
68
use vars qw(@ISA @EXPORT);
68
use vars qw(@ISA @EXPORT);
69
69
70
use Koha::SimpleMARC qw( read_field );
70
use Koha::SimpleMARC qw( read_field );
(-)a/C4/RotatingCollections.pm (-2 / +1 lines)
Lines 29-36 use C4::Circulation; Link Here
29
use C4::Reserves qw(CheckReserves);
29
use C4::Reserves qw(CheckReserves);
30
use Koha::Database;
30
use Koha::Database;
31
31
32
use DBI;
32
use Try::Tiny qw( catch try );
33
use Try::Tiny;
34
33
35
use vars qw(@ISA @EXPORT);
34
use vars qw(@ISA @EXPORT);
36
35
(-)a/C4/SIP/ILS.pm (-1 / +1 lines)
Lines 7-13 package C4::SIP::ILS; Link Here
7
use warnings;
7
use warnings;
8
use strict;
8
use strict;
9
use C4::SIP::Sip qw( siplog );
9
use C4::SIP::Sip qw( siplog );
10
use Data::Dumper;
10
use Data::Dumper qw( Dumper );
11
11
12
use C4::SIP::ILS::Item;
12
use C4::SIP::ILS::Item;
13
use C4::SIP::ILS::Patron;
13
use C4::SIP::ILS::Patron;
(-)a/C4/SIP/ILS/Item.pm (-6 / +4 lines)
Lines 9-32 package C4::SIP::ILS::Item; Link Here
9
use strict;
9
use strict;
10
use warnings;
10
use warnings;
11
11
12
use C4::SIP::Sip qw(siplog);
12
use C4::SIP::Sip qw( add_field siplog );
13
use Carp;
13
use Carp qw( croak );
14
use Template;
14
use Template;
15
15
16
use C4::SIP::ILS::Transaction;
16
use C4::SIP::ILS::Transaction;
17
use C4::SIP::Sip qw(add_field);
17
use C4::SIP::Sip qw( add_field siplog );
18
18
19
use C4::Biblio;
20
use C4::Circulation;
19
use C4::Circulation;
21
use C4::Context;
20
use C4::Context;
22
use C4::Items;
23
use C4::Members;
21
use C4::Members;
24
use C4::Reserves;
22
use C4::Reserves;
25
use Koha::Biblios;
23
use Koha::Biblios;
26
use Koha::Checkouts::ReturnClaims;
24
use Koha::Checkouts::ReturnClaims;
27
use Koha::Checkouts;
25
use Koha::Checkouts;
28
use Koha::Database;
26
use Koha::Database;
29
use Koha::DateUtils;
27
use Koha::DateUtils qw( dt_from_string );
30
use Koha::Holds;
28
use Koha::Holds;
31
use Koha::Items;
29
use Koha::Items;
32
use Koha::Patrons;
30
use Koha::Patrons;
(-)a/C4/SIP/ILS/Patron.pm (-5 / +5 lines)
Lines 10-27 package C4::SIP::ILS::Patron; Link Here
10
use strict;
10
use strict;
11
use warnings;
11
use warnings;
12
use Exporter;
12
use Exporter;
13
use Carp;
13
use Carp qw( croak );
14
14
15
use C4::SIP::Sip qw(siplog);
15
use C4::SIP::Sip qw( add_field maybe_add siplog );
16
use Data::Dumper;
16
use Data::Dumper qw( Dumper );
17
17
18
use C4::SIP::Sip qw(add_field maybe_add);
18
use C4::SIP::Sip qw( add_field maybe_add siplog );
19
19
20
use C4::Context;
20
use C4::Context;
21
use C4::Koha;
21
use C4::Koha;
22
use C4::Members;
22
use C4::Members;
23
use C4::Reserves;
23
use C4::Reserves;
24
use C4::Auth qw(checkpw);
24
use C4::Auth qw( checkpw );
25
25
26
use Koha::Items;
26
use Koha::Items;
27
use Koha::Libraries;
27
use Koha::Libraries;
(-)a/C4/SIP/ILS/Transaction.pm (-2 / +2 lines)
Lines 4-14 Link Here
4
4
5
package C4::SIP::ILS::Transaction;
5
package C4::SIP::ILS::Transaction;
6
6
7
use Carp;
7
use Carp qw( croak );
8
use strict;
8
use strict;
9
use warnings;
9
use warnings;
10
use C4::Context;
10
use C4::Context;
11
use Koha::DateUtils;
11
use Koha::DateUtils qw( dt_from_string );
12
use Koha::Checkouts;
12
use Koha::Checkouts;
13
13
14
my %fields = (
14
my %fields = (
(-)a/C4/SIP/ILS/Transaction/Checkout.pm (-4 / +2 lines)
Lines 7-15 package C4::SIP::ILS::Transaction::Checkout; Link Here
7
use warnings;
7
use warnings;
8
use strict;
8
use strict;
9
9
10
use POSIX qw(strftime);
10
use C4::SIP::Sip qw( siplog );
11
use C4::SIP::Sip qw(siplog);
11
use Data::Dumper qw( Dumper );
12
use Data::Dumper;
13
use CGI qw ( -utf8 );
12
use CGI qw ( -utf8 );
14
13
15
use C4::SIP::ILS::Transaction;
14
use C4::SIP::ILS::Transaction;
Lines 18-24 use C4::Context; Link Here
18
use C4::Circulation;
17
use C4::Circulation;
19
use C4::Members;
18
use C4::Members;
20
use C4::Reserves qw(ModReserveFill);
19
use C4::Reserves qw(ModReserveFill);
21
use Koha::DateUtils;
22
20
23
use parent qw(C4::SIP::ILS::Transaction);
21
use parent qw(C4::SIP::ILS::Transaction);
24
22
(-)a/C4/SIP/ILS/Transaction/Renew.pm (-1 lines)
Lines 9-15 use strict; Link Here
9
9
10
use C4::Circulation;
10
use C4::Circulation;
11
use Koha::Patrons;
11
use Koha::Patrons;
12
use Koha::DateUtils;
13
12
14
use parent qw(C4::SIP::ILS::Transaction);
13
use parent qw(C4::SIP::ILS::Transaction);
15
14
(-)a/C4/SIP/ILS/Transaction/RenewAll.pm (-1 / +1 lines)
Lines 6-12 package C4::SIP::ILS::Transaction::RenewAll; Link Here
6
use strict;
6
use strict;
7
use warnings;
7
use warnings;
8
8
9
use C4::SIP::Sip qw(siplog);
9
use C4::SIP::Sip qw( siplog );
10
10
11
use C4::SIP::ILS::Item;
11
use C4::SIP::ILS::Item;
12
12
(-)a/C4/SIP/SIPServer.pm (-7 / +4 lines)
Lines 4-24 package C4::SIP::SIPServer; Link Here
4
4
5
use strict;
5
use strict;
6
use warnings;
6
use warnings;
7
use FindBin qw($Bin);
7
use FindBin qw( $Bin );
8
use lib "$Bin";
8
use lib "$Bin";
9
use Net::Server::PreFork;
9
use Net::Server::PreFork;
10
use IO::Socket::INET;
10
use IO::Socket::INET qw( AF_INET6 inet_ntoa sockaddr_in sockaddr_in6 );
11
use Socket qw(:DEFAULT :crlf);
11
use Socket qw(:DEFAULT :crlf);
12
use Scalar::Util qw(blessed);
13
require UNIVERSAL::require;
14
12
15
use C4::Context;
13
use C4::Context;
16
use C4::SIP::Sip qw(siplog);
14
use C4::SIP::Sip qw( siplog );
17
use C4::SIP::Sip::Constants qw(:all);
15
use C4::SIP::Sip::Constants qw(:all);
18
use C4::SIP::Sip::Configuration;
16
use C4::SIP::Sip::Configuration;
19
use C4::SIP::Sip::Checksum qw(checksum verify_cksum);
20
use C4::SIP::Sip::MsgType qw( handle login_core );
17
use C4::SIP::Sip::MsgType qw( handle login_core );
21
use C4::SIP::Logger qw(set_logger);
18
use C4::SIP::Logger qw( set_logger );
22
19
23
use Koha::Caches;
20
use Koha::Caches;
24
21
(-)a/C4/SIP/Sip.pm (-7 / +7 lines)
Lines 7-21 package C4::SIP::Sip; Link Here
7
use strict;
7
use strict;
8
use warnings;
8
use warnings;
9
use Exporter;
9
use Exporter;
10
use Encode;
10
use Encode qw( encode );
11
use POSIX qw(strftime);
11
use POSIX qw( strftime );
12
use Socket qw(:crlf);
12
use Socket qw(:crlf);
13
use IO::Handle;
13
use IO::Handle qw( print );
14
use List::Util qw(first);
14
use List::Util qw( first );
15
15
16
use C4::SIP::Sip::Constants qw(SIP_DATETIME FID_SCREEN_MSG);
16
use C4::SIP::Sip::Constants qw( FID_SCREEN_MSG SIP_DATETIME );
17
use C4::SIP::Sip::Checksum qw(checksum);
17
use C4::SIP::Sip::Checksum qw( checksum );
18
use C4::SIP::Logger qw( get_logger );
18
use C4::SIP::Logger ();
19
19
20
use base qw(Exporter);
20
use base qw(Exporter);
21
21
(-)a/C4/SIP/Sip/Configuration.pm (-1 / +1 lines)
Lines 10-16 use strict; Link Here
10
use warnings;
10
use warnings;
11
use XML::Simple qw(:strict);
11
use XML::Simple qw(:strict);
12
12
13
use C4::SIP::Sip qw(siplog);
13
use C4::SIP::Sip qw( siplog );
14
14
15
my $parser = XML::Simple->new(
15
my $parser = XML::Simple->new(
16
    KeyAttr => {
16
    KeyAttr => {
(-)a/C4/SIP/Sip/MsgType.pm (-2 / +2 lines)
Lines 12-20 use Exporter; Link Here
12
12
13
use C4::SIP::Sip qw(:all);
13
use C4::SIP::Sip qw(:all);
14
use C4::SIP::Sip::Constants qw(:all);
14
use C4::SIP::Sip::Constants qw(:all);
15
use C4::SIP::Sip::Checksum qw(verify_cksum);
15
use C4::SIP::Sip::Checksum qw( verify_cksum );
16
16
17
use Data::Dumper;
17
use Data::Dumper qw( Dumper );
18
use CGI qw ( -utf8 );
18
use CGI qw ( -utf8 );
19
use C4::Auth qw(&check_api_auth);
19
use C4::Auth qw(&check_api_auth);
20
20
(-)a/C4/SIP/t/SIPtest.pm (-4 / +4 lines)
Lines 6-12 use warnings; Link Here
6
use Exporter;
6
use Exporter;
7
use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
7
use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
8
8
9
use Data::Dumper;
9
use Data::Dumper qw( Dumper );
10
10
11
BEGIN {
11
BEGIN {
12
	@ISA = qw(Exporter);
12
	@ISA = qw(Exporter);
Lines 37-48 BEGIN { Link Here
37
37
38
# The number of tests is set in run_sip_tests() below, based
38
# The number of tests is set in run_sip_tests() below, based
39
# on the size of the array of tests.
39
# on the size of the array of tests.
40
use Test::More;
40
use Test::More import => [ qw( BAIL_OUT diag fail pass plan ) ];
41
use CGI qw ( -utf8 );
41
use CGI qw ( -utf8 );
42
42
43
use IO::Socket::INET;
43
use IO::Socket::INET qw( SOCK_STREAM );
44
use C4::SIP::Sip qw(:all);
44
use C4::SIP::Sip qw(:all);
45
use C4::SIP::Sip::Checksum qw(verify_cksum);
45
use C4::SIP::Sip::Checksum qw( verify_cksum );
46
use C4::SIP::Sip::Constants qw(:all);
46
use C4::SIP::Sip::Constants qw(:all);
47
47
48
use C4::Auth qw(&check_api_auth);
48
use C4::Auth qw(&check_api_auth);
(-)a/C4/SMS.pm (-1 / +1 lines)
Lines 54-60 use strict; Link Here
54
use warnings;
54
use warnings;
55
55
56
use C4::Context;
56
use C4::Context;
57
use File::Spec;
57
use File::Spec ();
58
58
59
59
60
60
(-)a/C4/Scrubber.pm (-1 / +1 lines)
Lines 21-27 package C4::Scrubber; Link Here
21
21
22
use strict;
22
use strict;
23
use warnings;
23
use warnings;
24
use Carp;
24
use Carp qw( carp croak );
25
use HTML::Scrubber;
25
use HTML::Scrubber;
26
26
27
use C4::Context;
27
use C4::Context;
(-)a/C4/Search.pm (-7 / +10 lines)
Lines 17-28 package C4::Search; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use C4::Context;
19
use C4::Context;
20
use C4::Biblio qw( TransformMarcToKoha GetMarcFromKohaField GetFrameworkCode GetAuthorisedValueDesc GetBiblioData );
20
use C4::Biblio qw(
21
    GetAuthorisedValueDesc
22
    GetFrameworkCode
23
    GetMarcFromKohaField
24
    TransformMarcToKoha
25
);
21
use C4::Koha qw( getFacets GetVariationsOfISBN GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN getitemtypeimagelocation );
26
use C4::Koha qw( getFacets GetVariationsOfISBN GetNormalizedUPC GetNormalizedEAN GetNormalizedOCLCNumber GetNormalizedISBN getitemtypeimagelocation );
22
use Koha::DateUtils;
23
use Koha::Libraries;
27
use Koha::Libraries;
24
use Lingua::Stem;
28
use Lingua::Stem ();
25
use XML::Simple;
26
use C4::XSLT;
29
use C4::XSLT;
27
use C4::Reserves qw( GetReserveStatus );
30
use C4::Reserves qw( GetReserveStatus );
28
use C4::Charset qw( SetUTF8Flag );
31
use C4::Charset qw( SetUTF8Flag );
Lines 32-40 use Koha::Libraries; Link Here
32
use Koha::Logger;
35
use Koha::Logger;
33
use Koha::Patrons;
36
use Koha::Patrons;
34
use Koha::RecordProcessor;
37
use Koha::RecordProcessor;
35
use URI::Escape;
38
use URI::Escape qw( uri_escape_utf8 );
36
use Business::ISBN;
39
use Business::ISBN ();
37
use MARC::Record;
40
use MARC::Record ();
38
use MARC::Field;
41
use MARC::Field;
39
42
40
our (@ISA, @EXPORT_OK);
43
our (@ISA, @EXPORT_OK);
(-)a/C4/Search/History.pm (-4 / +3 lines)
Lines 4-14 use Modern::Perl; Link Here
4
4
5
use C4::Auth qw( get_session );
5
use C4::Auth qw( get_session );
6
use C4::Context;
6
use C4::Context;
7
use Koha::DateUtils;
7
use Koha::DateUtils qw( dt_from_string output_pref );
8
8
9
use JSON qw( encode_json decode_json );
9
use JSON qw( decode_json encode_json );
10
use URI::Escape;
10
use URI::Escape qw( uri_escape uri_unescape );
11
use Encode;
12
11
13
sub add {
12
sub add {
14
    my ($params)   = @_;
13
    my ($params)   = @_;
(-)a/C4/Search/PazPar2.pm (-3 / +3 lines)
Lines 19-28 package C4::Search::PazPar2; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use LWP::UserAgent;
22
use LWP::UserAgent ();
23
use URI;
23
use URI ();
24
use URI::QueryParam;
24
use URI::QueryParam;
25
use XML::Simple;
25
use XML::Simple qw( XMLin );
26
26
27
=head1 NAME
27
=head1 NAME
28
28
(-)a/C4/Serials.pm (-5 / +5 lines)
Lines 24-36 use C4::Auth qw( haspermission ); Link Here
24
use C4::Context;
24
use C4::Context;
25
use DateTime;
25
use DateTime;
26
use Date::Calc qw(:all);
26
use Date::Calc qw(:all);
27
use POSIX qw(strftime);
27
use POSIX qw( strftime );
28
use C4::Biblio qw( GetMarcBiblio GetMarcFromKohaField ModBiblio );
28
use C4::Biblio qw( GetMarcBiblio GetMarcFromKohaField ModBiblio );
29
use C4::Log;    # logaction
29
use C4::Log qw( logaction );    # logaction
30
use C4::Serials::Frequency;
30
use C4::Serials::Frequency qw( GetSubscriptionFrequency );
31
use C4::Serials::Numberpattern;
31
use C4::Serials::Numberpattern ();
32
use Koha::AdditionalFieldValues;
32
use Koha::AdditionalFieldValues;
33
use Koha::DateUtils;
33
use Koha::DateUtils qw( dt_from_string output_pref );
34
use Koha::Serial;
34
use Koha::Serial;
35
use Koha::Subscriptions;
35
use Koha::Subscriptions;
36
use Koha::Subscription::Histories;
36
use Koha::Subscription::Histories;
(-)a/C4/Service.pm (-1 / +1 lines)
Lines 45-51 use CGI qw ( -utf8 ); Link Here
45
use C4::Auth qw( check_api_auth );
45
use C4::Auth qw( check_api_auth );
46
use C4::Output qw( output_with_http_headers );
46
use C4::Output qw( output_with_http_headers );
47
use C4::Output qw( output_with_http_headers );
47
use C4::Output qw( output_with_http_headers );
48
use JSON;
48
use JSON ();
49
49
50
our $debug;
50
our $debug;
51
51
(-)a/C4/SocialData.pm (-1 / +1 lines)
Lines 18-24 package C4::SocialData; Link Here
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use C4::Context;
20
use C4::Context;
21
use Business::ISBN;
21
use Business::ISBN ();
22
use C4::Koha qw( GetNormalizedISBN );
22
use C4::Koha qw( GetNormalizedISBN );
23
23
24
=head1 NAME
24
=head1 NAME
(-)a/C4/Stats.pm (-1 / +1 lines)
Lines 20-26 package C4::Stats; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
require Exporter;
22
require Exporter;
23
use Carp;
23
use Carp qw( croak );
24
use C4::Context;
24
use C4::Context;
25
25
26
use Koha::DateUtils qw( dt_from_string );
26
use Koha::DateUtils qw( dt_from_string );
(-)a/C4/Suggestions.pm (-2 / +1 lines)
Lines 25-34 use C4::Context; Link Here
25
use C4::Output;
25
use C4::Output;
26
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
26
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
27
use C4::Biblio qw( GetMarcFromKohaField );
27
use C4::Biblio qw( GetMarcFromKohaField );
28
use Koha::DateUtils;
28
use Koha::DateUtils qw( dt_from_string );
29
use Koha::Suggestions;
29
use Koha::Suggestions;
30
30
31
use List::MoreUtils qw(any);
32
use base qw(Exporter);
31
use base qw(Exporter);
33
32
34
our @EXPORT  = qw(
33
our @EXPORT  = qw(
(-)a/C4/Tags.pm (-2 / +2 lines)
Lines 20-30 package C4::Tags; Link Here
20
20
21
use strict;
21
use strict;
22
use warnings;
22
use warnings;
23
use Carp;
23
use Carp qw( carp );
24
use Exporter;
24
use Exporter;
25
25
26
use C4::Context;
26
use C4::Context;
27
use Module::Load::Conditional qw/check_install/;
27
use Module::Load::Conditional qw( check_install );
28
#use Data::Dumper;
28
#use Data::Dumper;
29
use constant TAG_FIELDS => qw(tag_id borrowernumber biblionumber term language date_created);
29
use constant TAG_FIELDS => qw(tag_id borrowernumber biblionumber term language date_created);
30
use constant TAG_SELECT => "SELECT " . join(',', TAG_FIELDS) . "\n FROM   tags_all\n";
30
use constant TAG_SELECT => "SELECT " . join(',', TAG_FIELDS) . "\n FROM   tags_all\n";
(-)a/C4/Templates.pm (-3 / +3 lines)
Lines 2-10 package C4::Templates; Link Here
2
2
3
use strict;
3
use strict;
4
use warnings;
4
use warnings;
5
use Carp;
5
use Carp qw( carp );
6
use CGI qw ( -utf8 );
6
use CGI qw ( -utf8 );
7
use List::MoreUtils qw/ any uniq /;
7
use List::MoreUtils qw( uniq );
8
8
9
# Copyright 2009 Chris Cormack and The Koha Dev Team
9
# Copyright 2009 Chris Cormack and The Koha Dev Team
10
#
10
#
Lines 32-38 C4::Templates - Object for manipulating templates for use with Koha Link Here
32
use base qw(Class::Accessor);
32
use base qw(Class::Accessor);
33
use Template;
33
use Template;
34
use Template::Constants qw( :debug );
34
use Template::Constants qw( :debug );
35
use C4::Languages qw( regex_lang_subtags get_bidi getTranslatedLanguages getlanguage );
35
use C4::Languages qw( get_bidi getTranslatedLanguages regex_lang_subtags );
36
36
37
use C4::Context;
37
use C4::Context;
38
38
(-)a/C4/TmplToken.pm (-1 / +1 lines)
Lines 20-26 package C4::TmplToken; Link Here
20
20
21
use strict;
21
use strict;
22
use warnings;
22
use warnings;
23
use C4::TmplTokenType qw( DIRECTIVE TAG CDATA TEXT TEXT_PARAMETRIZED );
23
use C4::TmplTokenType ();
24
24
25
=head1 NAME
25
=head1 NAME
26
26
(-)a/C4/UsageStats.pm (-3 / +3 lines)
Lines 19-27 package C4::UsageStats; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use C4::Context;
21
use C4::Context;
22
use POSIX qw(strftime);
22
use POSIX qw( strftime );
23
use LWP::UserAgent;
23
use LWP::UserAgent ();
24
use JSON;
24
use JSON qw( decode_json encode_json );
25
25
26
use Koha::Libraries;
26
use Koha::Libraries;
27
27
(-)a/C4/Utils/DataTables/Members.pm (-2 / +2 lines)
Lines 2-9 package C4::Utils::DataTables::Members; Link Here
2
2
3
use Modern::Perl;
3
use Modern::Perl;
4
use C4::Context;
4
use C4::Context;
5
use C4::Utils::DataTables;
5
use C4::Utils::DataTables qw( dt_build_orderby );
6
use Koha::DateUtils;
6
use Koha::DateUtils qw( dt_from_string output_pref );
7
7
8
sub search {
8
sub search {
9
    my ( $params ) = @_;
9
    my ( $params ) = @_;
(-)a/C4/Utils/DataTables/TablesSettings.pm (-1 / +1 lines)
Lines 2-8 package C4::Utils::DataTables::TablesSettings; Link Here
2
2
3
use Modern::Perl;
3
use Modern::Perl;
4
use List::Util qw( first );
4
use List::Util qw( first );
5
use YAML::XS;
5
use YAML::XS ();
6
use C4::Context;
6
use C4::Context;
7
use Koha::Database;
7
use Koha::Database;
8
use Koha::Caches;
8
use Koha::Caches;
(-)a/C4/Utils/DataTables/VirtualShelves.pm (-1 / +1 lines)
Lines 2-8 package C4::Utils::DataTables::VirtualShelves; Link Here
2
2
3
use Modern::Perl;
3
use Modern::Perl;
4
use C4::Context;
4
use C4::Context;
5
use C4::Utils::DataTables;
5
use C4::Utils::DataTables qw( dt_build_orderby );
6
use Koha::Virtualshelves;
6
use Koha::Virtualshelves;
7
7
8
sub search {
8
sub search {
(-)a/C4/XISBN.pm (-5 / +4 lines)
Lines 18-31 package C4::XISBN; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use XML::Simple;
21
use XML::Simple ();
22
#use LWP::Simple;
22
#use LWP::Simple;
23
use C4::Biblio qw( TransformMarcToKoha TransformMarcToKohaOneField );
23
use C4::Biblio ();
24
use C4::Koha qw( GetNormalizedISBN );
24
use C4::Koha qw( GetNormalizedISBN );
25
use C4::Search qw( new_record_from_zebra );
25
use C4::Search qw( new_record_from_zebra );
26
use C4::External::Syndetics qw(get_syndetics_editions);
26
use C4::External::Syndetics qw( get_syndetics_editions );
27
use LWP::UserAgent;
27
use LWP::UserAgent ();
28
use HTTP::Request::Common;
29
28
30
use Koha::Biblios;
29
use Koha::Biblios;
31
use Koha::SearchEngine;
30
use Koha::SearchEngine;
(-)a/C4/XSLT.pm (-2 / +1 lines)
Lines 25-31 use Modern::Perl; Link Here
25
25
26
use C4::Context;
26
use C4::Context;
27
use C4::Koha qw( xml_escape );
27
use C4::Koha qw( xml_escape );
28
use C4::Biblio qw( GetFrameworkCode GetMarcStructure GetAuthorisedValueDesc );
28
use C4::Biblio qw( GetAuthorisedValueDesc GetFrameworkCode GetMarcStructure );
29
use C4::Circulation;
29
use C4::Circulation;
30
use C4::Reserves;
30
use C4::Reserves;
31
use Koha::AuthorisedValues;
31
use Koha::AuthorisedValues;
Lines 33-39 use Koha::ItemTypes; Link Here
33
use Koha::XSLT::Base;
33
use Koha::XSLT::Base;
34
use Koha::Libraries;
34
use Koha::Libraries;
35
35
36
use Encode;
37
36
38
use vars qw(@ISA @EXPORT);
37
use vars qw(@ISA @EXPORT);
39
38
(-)a/Koha/Account.pm (-6 / +4 lines)
Lines 19-31 package Koha::Account; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
22
use Carp ();
23
use Data::Dumper;
23
use Data::Dumper qw( Dumper );
24
use List::MoreUtils qw( uniq );
24
use Try::Tiny qw( catch try );
25
use Try::Tiny;
26
25
27
use C4::Circulation qw( ReturnLostItem CanBookBeRenewed AddRenewal );
26
use C4::Circulation qw( ReturnLostItem CanBookBeRenewed AddRenewal );
28
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
27
use C4::Letters ();
29
use C4::Log qw( logaction );
28
use C4::Log qw( logaction );
30
use C4::Stats qw( UpdateStats );
29
use C4::Stats qw( UpdateStats );
31
use C4::Overdues qw(GetFine);
30
use C4::Overdues qw(GetFine);
Lines 34-40 use Koha::Patrons; Link Here
34
use Koha::Account::Lines;
33
use Koha::Account::Lines;
35
use Koha::Account::Offsets;
34
use Koha::Account::Offsets;
36
use Koha::Account::DebitTypes;
35
use Koha::Account::DebitTypes;
37
use Koha::DateUtils qw( dt_from_string );
38
use Koha::Exceptions;
36
use Koha::Exceptions;
39
use Koha::Exceptions::Account;
37
use Koha::Exceptions::Account;
40
38
(-)a/Koha/Account/CreditType.pm (-1 lines)
Lines 18-24 package Koha::Account::CreditType; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use List::Util qw/any/;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
use Koha::Exceptions;
23
use Koha::Exceptions;
(-)a/Koha/Account/CreditTypes.pm (-1 lines)
Lines 18-24 package Koha::Account::CreditTypes; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use List::Util qw/any/;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
use Koha::Account::CreditType;
23
use Koha::Account::CreditType;
(-)a/Koha/Account/DebitType.pm (-1 lines)
Lines 18-24 package Koha::Account::DebitType; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use List::Util qw/any/;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
use Koha::Exceptions;
23
use Koha::Exceptions;
(-)a/Koha/Account/DebitTypes.pm (-1 lines)
Lines 18-24 package Koha::Account::DebitTypes; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use List::Util qw/any/;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
use Koha::Account::DebitType;
23
use Koha::Account::DebitType;
(-)a/Koha/Account/Line.pm (-4 / +3 lines)
Lines 17-33 package Koha::Account::Line; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
20
use Data::Dumper qw( Dumper );
21
use Data::Dumper;
22
21
23
use C4::Log qw(logaction);
22
use C4::Log qw( logaction );
24
use C4::Overdues qw( UpdateFine );
23
use C4::Overdues qw( UpdateFine );
25
24
26
use Koha::Account::CreditType;
25
use Koha::Account::CreditType;
27
use Koha::Account::DebitType;
26
use Koha::Account::DebitType;
28
use Koha::Account::Offsets;
27
use Koha::Account::Offsets;
29
use Koha::Database;
28
use Koha::Database;
30
use Koha::DateUtils;
29
use Koha::DateUtils qw( dt_from_string );
31
use Koha::Exceptions::Account;
30
use Koha::Exceptions::Account;
32
use Koha::Items;
31
use Koha::Items;
33
32
(-)a/Koha/Account/Lines.pm (-1 lines)
Lines 17-23 package Koha::Account::Lines; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Account::Line;
22
use Koha::Account::Line;
(-)a/Koha/Account/Offset.pm (-1 lines)
Lines 17-23 package Koha::Account::Offset; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Account::Lines;
22
use Koha::Account::Lines;
(-)a/Koha/Account/Offsets.pm (-1 lines)
Lines 17-23 package Koha::Account::Offsets; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Acquisition/Basket.pm (-1 / +1 lines)
Lines 25-31 use Koha::Acquisition::BasketGroups; Link Here
25
use Koha::Acquisition::Orders;
25
use Koha::Acquisition::Orders;
26
use Koha::Exceptions::Acquisition::Basket;
26
use Koha::Exceptions::Acquisition::Basket;
27
use Koha::Patrons;
27
use Koha::Patrons;
28
use C4::Log qw(logaction);
28
use C4::Log qw( logaction );
29
29
30
use base qw( Koha::Object Koha::Object::Mixin::AdditionalFields );
30
use base qw( Koha::Object Koha::Object::Mixin::AdditionalFields );
31
31
(-)a/Koha/Acquisition/Bookseller/Contact.pm (-1 lines)
Lines 4-10 use Modern::Perl; Link Here
4
4
5
use base qw( Koha::Object );
5
use base qw( Koha::Object );
6
6
7
use Carp qw( croak );
8
7
9
sub _type {
8
sub _type {
10
    return 'Aqcontact';
9
    return 'Aqcontact';
(-)a/Koha/Acquisition/Bookseller/Contacts.pm (-1 lines)
Lines 2-8 package Koha::Acquisition::Bookseller::Contacts; Link Here
2
2
3
use Modern::Perl;
3
use Modern::Perl;
4
4
5
use Carp;
6
5
7
use base qw( Koha::Objects );
6
use base qw( Koha::Objects );
8
7
(-)a/Koha/Acquisition/Currencies.pm (-1 lines)
Lines 17-23 package Koha::Acquisition::Currencies; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Acquisition/Currency.pm (-1 lines)
Lines 17-23 package Koha::Acquisition::Currency; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Acquisition/Invoice/Adjustment.pm (-1 lines)
Lines 17-23 package Koha::Acquisition::Invoice::Adjustment; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Acquisition::Invoices;
22
use Koha::Acquisition::Invoices;
(-)a/Koha/Acquisition/Invoice/Adjustments.pm (-1 lines)
Lines 18-24 package Koha::Acquisition::Invoice::Adjustments; Link Here
18
use Modern::Perl;
18
use Modern::Perl;
19
use Koha::Acquisition::Invoice::Adjustment;
19
use Koha::Acquisition::Invoice::Adjustment;
20
20
21
use Carp;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
23
(-)a/Koha/Acquisition/Order.pm (-2 / +1 lines)
Lines 18-24 package Koha::Acquisition::Order; Link Here
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp qw( croak );
20
use Carp qw( croak );
21
use Try::Tiny;
22
21
23
use C4::Biblio qw( DelBiblio );
22
use C4::Biblio qw( DelBiblio );
24
23
Lines 27-33 use Koha::Acquisition::Funds; Link Here
27
use Koha::Acquisition::Invoices;
26
use Koha::Acquisition::Invoices;
28
use Koha::Acquisition::Order::Claims;
27
use Koha::Acquisition::Order::Claims;
29
use Koha::Database;
28
use Koha::Database;
30
use Koha::DateUtils qw( dt_from_string output_pref );
29
use Koha::DateUtils qw( dt_from_string );
31
use Koha::Exceptions::Object;
30
use Koha::Exceptions::Object;
32
use Koha::Biblios;
31
use Koha::Biblios;
33
use Koha::Holds;
32
use Koha::Holds;
(-)a/Koha/Acquisition/Order/Claim.pm (-1 lines)
Lines 17-23 package Koha::Acquisition::Order::Claim; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Acquisition/Order/Claims.pm (-1 lines)
Lines 17-23 package Koha::Acquisition::Order::Claims; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Acquisition/Orders.pm (-1 lines)
Lines 17-23 package Koha::Acquisition::Orders; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/AdvancedEditorMacro.pm (-1 lines)
Lines 16-22 package Koha::AdvancedEditorMacro; Link Here
16
16
17
use Modern::Perl;
17
use Modern::Perl;
18
18
19
use Carp;
20
19
21
use Koha::Database;
20
use Koha::Database;
22
21
(-)a/Koha/AdvancedEditorMacros.pm (-1 lines)
Lines 16-22 package Koha::AdvancedEditorMacros; Link Here
16
16
17
use Modern::Perl;
17
use Modern::Perl;
18
18
19
use Carp;
20
19
21
use Koha::Database;
20
use Koha::Database;
22
21
(-)a/Koha/ApiKey.pm (-2 / +1 lines)
Lines 19-30 package Koha::ApiKey; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Exceptions;
24
use Koha::Exceptions;
26
25
27
use UUID;
26
use UUID ();
28
27
29
use base qw(Koha::Object);
28
use base qw(Koha::Object);
30
29
(-)a/Koha/ApiKeys.pm (-1 lines)
Lines 19-25 package Koha::ApiKeys; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::ApiKey;
24
use Koha::ApiKey;
(-)a/Koha/App/Plugin/CGIBinKoha.pm (-1 / +1 lines)
Lines 21-27 use Modern::Perl; Link Here
21
21
22
use Mojo::Base 'Mojolicious::Plugin';
22
use Mojo::Base 'Mojolicious::Plugin';
23
23
24
use CGI;
24
use CGI ();
25
use CGI::Compile;
25
use CGI::Compile;
26
use CGI::Emulate::PSGI;
26
use CGI::Emulate::PSGI;
27
use IO::Scalar;
27
use IO::Scalar;
(-)a/Koha/ArticleRequest.pm (-2 / +1 lines)
Lines 19-32 package Koha::ArticleRequest; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Patrons;
24
use Koha::Patrons;
26
use Koha::Biblios;
25
use Koha::Biblios;
27
use Koha::Items;
26
use Koha::Items;
28
use Koha::Libraries;
27
use Koha::Libraries;
29
use Koha::DateUtils qw(dt_from_string);
28
use Koha::DateUtils qw( dt_from_string );
30
29
31
use base qw(Koha::Object);
30
use base qw(Koha::Object);
32
31
(-)a/Koha/ArticleRequests.pm (-1 lines)
Lines 19-25 package Koha::ArticleRequests; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/AudioAlert.pm (-1 lines)
Lines 19-25 package Koha::AudioAlert; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/AudioAlerts.pm (-1 lines)
Lines 19-25 package Koha::AudioAlerts; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/AuthUtils.pm (-4 / +4 lines)
Lines 18-27 package Koha::AuthUtils; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Crypt::Eksblowfish::Bcrypt qw(bcrypt en_base64);
21
use Crypt::Eksblowfish::Bcrypt qw( bcrypt en_base64 );
22
use Encode qw( encode is_utf8 );
22
use Encode ();
23
use Fcntl qw/O_RDONLY/; # O_RDONLY is used in generate_salt
23
use Fcntl qw( O_RDONLY ); # O_RDONLY is used in generate_salt
24
use List::MoreUtils qw/ any /;
24
use List::MoreUtils qw( any );
25
use String::Random qw( random_string );
25
use String::Random qw( random_string );
26
use Koha::Exceptions::Password;
26
use Koha::Exceptions::Password;
27
27
(-)a/Koha/AuthorisedValue.pm (-1 lines)
Lines 19-25 package Koha::AuthorisedValue; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/AuthorisedValueCategories.pm (-1 lines)
Lines 17-23 package Koha::AuthorisedValueCategories; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Exceptions;
22
use Koha::Exceptions;
(-)a/Koha/AuthorisedValueCategory.pm (-1 lines)
Lines 17-23 package Koha::AuthorisedValueCategory; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Exceptions;
22
use Koha::Exceptions;
(-)a/Koha/AuthorisedValues.pm (-1 lines)
Lines 19-25 package Koha::AuthorisedValues; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Authorities.pm (-1 lines)
Lines 19-25 package Koha::Authorities; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Authority/MergeRequests.pm (-2 / +1 lines)
Lines 19-30 package Koha::Authority::MergeRequests; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use MARC::File::XML;
21
use MARC::File::XML;
22
use MARC::Record;
23
22
24
use C4::Context;
23
use C4::Context;
25
use Koha::Authority::MergeRequest;
24
use Koha::Authority::MergeRequest;
26
use Koha::Database;
25
use Koha::Database;
27
use Koha::DateUtils;
26
use Koha::DateUtils qw( dt_from_string );
28
27
29
use parent qw(Koha::Objects);
28
use parent qw(Koha::Objects);
30
29
(-)a/Koha/Authority/Type.pm (-1 lines)
Lines 17-23 package Koha::Authority::Type; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Authority/Types.pm (-1 lines)
Lines 17-23 package Koha::Authority::Types; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/BackgroundJob.pm (-2 / +2 lines)
Lines 16-25 package Koha::BackgroundJob; Link Here
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use JSON qw( encode_json decode_json );
19
use JSON qw( decode_json encode_json );
20
use Carp qw( croak );
20
use Carp qw( croak );
21
use Net::Stomp;
21
use Net::Stomp;
22
use Try::Tiny;
22
use Try::Tiny qw( catch try );
23
23
24
use C4::Context;
24
use C4::Context;
25
use Koha::DateUtils qw( dt_from_string );
25
use Koha::DateUtils qw( dt_from_string );
(-)a/Koha/BackgroundJob/BatchUpdateAuthority.pm (-2 / +2 lines)
Lines 16-24 package Koha::BackgroundJob::BatchUpdateAuthority; Link Here
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use JSON qw( encode_json decode_json );
19
use JSON qw( decode_json encode_json );
20
20
21
use C4::MarcModificationTemplates;
21
use C4::MarcModificationTemplates qw( ModifyRecordWithTemplate );
22
use C4::AuthoritiesMarc;
22
use C4::AuthoritiesMarc;
23
use Koha::BackgroundJobs;
23
use Koha::BackgroundJobs;
24
use Koha::DateUtils qw( dt_from_string );
24
use Koha::DateUtils qw( dt_from_string );
(-)a/Koha/BackgroundJob/BatchUpdateBiblio.pm (-3 / +3 lines)
Lines 16-27 package Koha::BackgroundJob::BatchUpdateBiblio; Link Here
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use JSON qw( encode_json decode_json );
19
use JSON qw( decode_json encode_json );
20
20
21
use Koha::BackgroundJobs;
21
use Koha::BackgroundJobs;
22
use Koha::DateUtils qw( dt_from_string );
22
use Koha::DateUtils qw( dt_from_string );
23
use C4::Biblio qw( GetMarcBiblio GetFrameworkCode ModBiblio );
23
use C4::Biblio ();
24
use C4::MarcModificationTemplates;
24
use C4::MarcModificationTemplates ();
25
25
26
use base 'Koha::BackgroundJob';
26
use base 'Koha::BackgroundJob';
27
27
(-)a/Koha/Biblio.pm (-5 / +3 lines)
Lines 19-31 package Koha::Biblio; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
22
use List::MoreUtils qw( any );
23
use List::MoreUtils qw(any);
23
use URI ();
24
use URI;
24
use URI::Escape qw( uri_escape_utf8 );
25
use URI::Escape;
26
25
27
use C4::Koha qw( GetNormalizedISBN );
26
use C4::Koha qw( GetNormalizedISBN );
28
use C4::Biblio qw();
29
27
30
use Koha::Database;
28
use Koha::Database;
31
use Koha::DateUtils qw( dt_from_string );
29
use Koha::DateUtils qw( dt_from_string );
(-)a/Koha/Biblio/Metadata.pm (-1 / +1 lines)
Lines 17-23 package Koha::Biblio::Metadata; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use MARC::Record;
20
use MARC::Record ();
21
use MARC::File::XML;
21
use MARC::File::XML;
22
22
23
use Koha::Database;
23
use Koha::Database;
(-)a/Koha/Biblio/Metadatas.pm (-1 lines)
Lines 17-23 package Koha::Biblio::Metadatas; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/BiblioFramework.pm (-1 lines)
Lines 17-23 package Koha::BiblioFramework; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/BiblioFrameworks.pm (-1 lines)
Lines 17-23 package Koha::BiblioFrameworks; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/BiblioUtils.pm (-2 / +1 lines)
Lines 32-43 the new thing that should be used. Link Here
32
32
33
=cut
33
=cut
34
34
35
use C4::Biblio qw( GetMarcBiblio );
35
use C4::Biblio ();
36
use Koha::MetadataIterator;
36
use Koha::MetadataIterator;
37
use Koha::Database;
37
use Koha::Database;
38
use Modern::Perl;
38
use Modern::Perl;
39
39
40
use Data::Dumper; # TODO remove
41
40
42
use base qw(Koha::MetadataRecord);
41
use base qw(Koha::MetadataRecord);
43
42
(-)a/Koha/BiblioUtils/Iterator.pm (-3 / +3 lines)
Lines 43-52 Returns biblionumber and marc in list context. Link Here
43
43
44
=cut
44
=cut
45
45
46
use C4::Biblio qw( GetXmlBiblio EmbedItemsInMarcBiblio );
46
use C4::Biblio ();
47
47
48
use Carp;
48
use Carp qw( confess );
49
use MARC::Record;
49
use MARC::Record ();
50
use MARC::File::XML;
50
use MARC::File::XML;
51
use Modern::Perl;
51
use Modern::Perl;
52
52
(-)a/Koha/Biblioitem.pm (-1 lines)
Lines 17-23 package Koha::Biblioitem; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Biblioitems.pm (-1 lines)
Lines 17-23 package Koha::Biblioitems; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Biblios.pm (-1 lines)
Lines 19-25 package Koha::Biblios; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Cache.pm (-4 / +4 lines)
Lines 40-49 The first, traditional OO interface provides the following functions: Link Here
40
40
41
use strict;
41
use strict;
42
use warnings;
42
use warnings;
43
use Carp;
43
use Carp qw( carp croak );
44
use Module::Load::Conditional qw(can_load);
44
use Module::Load::Conditional qw( can_load );
45
use Sereal::Encoder;
45
use Sereal::Encoder ();
46
use Sereal::Decoder;
46
use Sereal::Decoder ();
47
47
48
use C4::Context;
48
use C4::Context;
49
use Koha::Cache::Object;
49
use Koha::Cache::Object;
(-)a/Koha/Cache/Object.pm (-1 / +1 lines)
Lines 52-58 scalars and hashes, with arrays a potential future addition. Link Here
52
52
53
use strict;
53
use strict;
54
use warnings;
54
use warnings;
55
use Carp;
55
use Carp qw( carp );
56
56
57
use base qw(Class::Accessor);
57
use base qw(Class::Accessor);
58
58
(-)a/Koha/Calendar.pm (-1 / +1 lines)
Lines 2-8 package Koha::Calendar; Link Here
2
2
3
use Modern::Perl;
3
use Modern::Perl;
4
4
5
use Carp;
5
use Carp qw( croak );
6
use DateTime;
6
use DateTime;
7
use DateTime::Duration;
7
use DateTime::Duration;
8
use C4::Context;
8
use C4::Context;
(-)a/Koha/Cash/Register.pm (-1 lines)
Lines 17-23 package Koha::Cash::Register; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Account::Lines;
21
use Koha::Account::Lines;
23
use Koha::Account::Offsets;
22
use Koha::Account::Offsets;
(-)a/Koha/Cash/Register/Action.pm (-1 lines)
Lines 17-23 package Koha::Cash::Register::Action; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Cash/Register/Actions.pm (-1 lines)
Lines 17-23 package Koha::Cash::Register::Actions; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Cash/Register/Cashup.pm (-1 lines)
Lines 17-23 package Koha::Cash::Register::Cashup; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Cash/Register/Cashups.pm (-1 lines)
Lines 17-23 package Koha::Cash::Register::Cashups; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Cash::Register::Cashup;
22
use Koha::Cash::Register::Cashup;
(-)a/Koha/Cash/Registers.pm (-1 lines)
Lines 17-23 package Koha::Cash::Registers; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Charges/Fees.pm (-1 / +1 lines)
Lines 19-25 package Koha::Charges::Fees; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp qw( carp confess );
22
use Carp ();
23
23
24
use Koha::Calendar;
24
use Koha::Calendar;
25
use Koha::DateUtils qw( dt_from_string );
25
use Koha::DateUtils qw( dt_from_string );
(-)a/Koha/Checkout.pm (-3 / +2 lines)
Lines 20-33 package Koha::Checkout; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
22
23
use Carp;
24
use DateTime;
23
use DateTime;
25
use Try::Tiny;
24
use Try::Tiny qw( catch try );
26
25
27
use C4::Circulation qw( LostItem MarkIssueReturned );
26
use C4::Circulation qw( LostItem MarkIssueReturned );
28
use Koha::Checkouts::ReturnClaims;
27
use Koha::Checkouts::ReturnClaims;
29
use Koha::Database;
28
use Koha::Database;
30
use Koha::DateUtils;
29
use Koha::DateUtils qw( dt_from_string );
31
use Koha::Items;
30
use Koha::Items;
32
use Koha::Libraries;
31
use Koha::Libraries;
33
32
(-)a/Koha/Checkouts.pm (-2 / +1 lines)
Lines 19-31 package Koha::Checkouts; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use C4::Context;
23
use C4::Context;
25
use C4::Circulation qw( AddReturn );
24
use C4::Circulation qw( AddReturn );
26
use Koha::Checkout;
25
use Koha::Checkout;
27
use Koha::Database;
26
use Koha::Database;
28
use Koha::DateUtils;
27
use Koha::DateUtils qw( dt_from_string );
29
28
30
use base qw(Koha::Objects);
29
use base qw(Koha::Objects);
31
30
(-)a/Koha/Checkouts/ReturnClaims.pm (-1 lines)
Lines 19-25 package Koha::Checkouts::ReturnClaims; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/CirculationRules.pm (-1 / +1 lines)
Lines 18-24 package Koha::CirculationRules; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Carp qw(croak);
21
use Carp qw( croak );
22
22
23
use Koha::Exceptions;
23
use Koha::Exceptions;
24
use Koha::CirculationRule;
24
use Koha::CirculationRule;
(-)a/Koha/Cities.pm (-1 lines)
Lines 17-23 package Koha::Cities; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/City.pm (-1 lines)
Lines 17-23 package Koha::City; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/ClassSortRule.pm (-1 lines)
Lines 17-23 package Koha::ClassSortRule; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/ClassSortRules.pm (-1 lines)
Lines 17-23 package Koha::ClassSortRules; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/ClassSource.pm (-1 lines)
Lines 17-23 package Koha::ClassSource; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/ClassSources.pm (-1 lines)
Lines 17-23 package Koha::ClassSources; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/ClassSplitRule.pm (-1 / +1 lines)
Lines 17-23 package Koha::ClassSplitRule; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use JSON qw(to_json from_json);
20
use JSON qw( from_json to_json );
21
21
22
use Koha::Database;
22
use Koha::Database;
23
23
(-)a/Koha/Club.pm (-1 lines)
Lines 19-25 package Koha::Club; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Enrollment.pm (-2 / +1 lines)
Lines 19-30 package Koha::Club::Enrollment; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Clubs;
24
use Koha::Clubs;
26
use Koha::Patrons;
25
use Koha::Patrons;
27
use Koha::DateUtils qw(dt_from_string);
26
use Koha::DateUtils qw( dt_from_string );
28
use DateTime;
27
use DateTime;
29
28
30
use base qw(Koha::Object);
29
use base qw(Koha::Object);
(-)a/Koha/Club/Enrollment/Field.pm (-1 lines)
Lines 19-25 package Koha::Club::Enrollment::Field; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Enrollment/Fields.pm (-1 lines)
Lines 19-25 package Koha::Club::Enrollment::Fields; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Enrollments.pm (-1 lines)
Lines 19-25 package Koha::Club::Enrollments; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Field.pm (-1 lines)
Lines 19-25 package Koha::Club::Field; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Fields.pm (-1 lines)
Lines 19-25 package Koha::Club::Fields; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Hold.pm (-2 / +1 lines)
Lines 19-25 package Koha::Club::Hold; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
Lines 32-38 use Koha::Club::Hold::PatronHold; Link Here
32
use Koha::Clubs;
31
use Koha::Clubs;
33
use Koha::Patrons;
32
use Koha::Patrons;
34
33
35
use List::Util 'shuffle';
34
use List::Util qw( shuffle );
36
35
37
=head1 NAME
36
=head1 NAME
38
37
(-)a/Koha/Club/Hold/PatronHold.pm (-1 lines)
Lines 19-25 package Koha::Club::Hold::PatronHold; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Hold/PatronHolds.pm (-1 lines)
Lines 19-25 package Koha::Club::Hold::PatronHolds; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Holds.pm (-1 lines)
Lines 19-25 package Koha::Club::Holds; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Template.pm (-1 lines)
Lines 19-25 package Koha::Club::Template; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Template/EnrollmentField.pm (-1 lines)
Lines 19-25 package Koha::Club::Template::EnrollmentField; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Template/EnrollmentFields.pm (-1 lines)
Lines 19-25 package Koha::Club::Template::EnrollmentFields; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Template/Field.pm (-1 lines)
Lines 19-25 package Koha::Club::Template::Field; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Template/Fields.pm (-1 lines)
Lines 19-25 package Koha::Club::Template::Fields; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Club/Templates.pm (-1 lines)
Lines 19-25 package Koha::Club::Templates; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Clubs.pm (-1 lines)
Lines 19-25 package Koha::Clubs; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::DateUtils qw( dt_from_string );
24
use Koha::DateUtils qw( dt_from_string );
(-)a/Koha/Config/SysPref.pm (-2 / +1 lines)
Lines 19-29 package Koha::Config::SysPref; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
26
use C4::Log;
25
use C4::Log ();
27
26
28
use base qw(Koha::Object);
27
use base qw(Koha::Object);
29
28
(-)a/Koha/Config/SysPrefs.pm (-1 lines)
Lines 19-25 package Koha::Config::SysPrefs; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Course.pm (-1 lines)
Lines 17-23 package Koha::Course; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Course/Instructor.pm (-1 lines)
Lines 17-23 package Koha::Course::Instructor; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Course/Instructors.pm (-1 lines)
Lines 17-23 package Koha::Course::Instructors; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Course::Instructor;
21
use Koha::Course::Instructor;
23
22
(-)a/Koha/Course/Item.pm (-1 lines)
Lines 17-23 package Koha::Course::Item; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Course/Items.pm (-1 lines)
Lines 17-23 package Koha::Course::Items; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Course::Item;
21
use Koha::Course::Item;
23
22
(-)a/Koha/Course/Reserve.pm (-1 lines)
Lines 17-23 package Koha::Course::Reserve; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Course/Reserves.pm (-1 lines)
Lines 17-23 package Koha::Course::Reserves; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Course::Reserve;
21
use Koha::Course::Reserve;
23
22
(-)a/Koha/Courses.pm (-1 lines)
Lines 17-23 package Koha::Courses; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Course;
21
use Koha::Course;
23
22
(-)a/Koha/CoverImage.pm (-2 / +1 lines)
Lines 17-24 package Koha::CoverImage; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
20
use GD ();
21
use GD;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
23
(-)a/Koha/CoverImages.pm (-1 lines)
Lines 17-23 package Koha::CoverImages; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/CsvProfile.pm (-1 lines)
Lines 17-23 package Koha::CsvProfile; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/CsvProfiles.pm (-1 lines)
Lines 17-23 package Koha::CsvProfiles; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Database.pm (-1 lines)
Lines 33-39 Koha::Database Link Here
33
=cut
33
=cut
34
34
35
use Modern::Perl;
35
use Modern::Perl;
36
use Carp;
37
use C4::Context;
36
use C4::Context;
38
use base qw(Class::Accessor);
37
use base qw(Class::Accessor);
39
38
(-)a/Koha/Desk.pm (-1 lines)
Lines 18-24 package Koha::Desk; Link Here
18
18
19
use Modern::Perl;
19
use Modern::Perl;
20
20
21
use Carp;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
23
(-)a/Koha/Desks.pm (-1 lines)
Lines 19-25 package Koha::Desks; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/EDI.pm (-6 / +11 lines)
Lines 21-41 use strict; Link Here
21
use warnings;
21
use warnings;
22
use base qw(Exporter);
22
use base qw(Exporter);
23
use utf8;
23
use utf8;
24
use Carp;
24
use Carp qw( carp );
25
use English qw{ -no_match_vars };
25
use English qw{ -no_match_vars };
26
use Business::ISBN;
26
use Business::ISBN ();
27
use DateTime;
27
use DateTime;
28
use C4::Context;
28
use C4::Context;
29
use Koha::Database;
29
use Koha::Database;
30
use Koha::DateUtils;
30
use Koha::DateUtils qw( dt_from_string );
31
use C4::Acquisition qw( NewBasket ModOrder);
31
use C4::Acquisition qw( NewBasket ModOrder);
32
use C4::Suggestions qw( ModSuggestion );
32
use C4::Suggestions qw( ModSuggestion );
33
use C4::Biblio qw( GetFrameworkCode GetMarcFromKohaField AddBiblio TransformKohaToMarc );
33
use C4::Biblio qw(
34
    AddBiblio
35
    GetFrameworkCode
36
    GetMarcFromKohaField
37
    TransformKohaToMarc
38
);
34
use Koha::Edifact::Order;
39
use Koha::Edifact::Order;
35
use Koha::Edifact;
40
use Koha::Edifact;
36
use C4::Log qw(logaction);
41
use C4::Log qw( logaction );
37
use Log::Log4perl;
42
use Log::Log4perl;
38
use Text::Unidecode;
43
use Text::Unidecode qw( unidecode );
39
use Koha::Plugins::Handler;
44
use Koha::Plugins::Handler;
40
use Koha::Acquisition::Baskets;
45
use Koha::Acquisition::Baskets;
41
use Koha::Acquisition::Booksellers;
46
use Koha::Acquisition::Booksellers;
(-)a/Koha/Edifact.pm (-3 / +2 lines)
Lines 19-27 package Koha::Edifact; Link Here
19
19
20
use strict;
20
use strict;
21
use warnings;
21
use warnings;
22
use File::Slurp;
22
use File::Slurp qw( read_file );
23
use Carp;
23
use Carp qw( carp croak );
24
use Encode qw( from_to );
25
use Koha::Edifact::Segment;
24
use Koha::Edifact::Segment;
26
use Koha::Edifact::Message;
25
use Koha::Edifact::Message;
27
26
(-)a/Koha/Edifact/Line.pm (-2 / +2 lines)
Lines 21-29 use strict; Link Here
21
use warnings;
21
use warnings;
22
use utf8;
22
use utf8;
23
23
24
use MARC::Record;
24
use MARC::Record ();
25
use MARC::Field;
25
use MARC::Field;
26
use Carp;
26
use Carp qw( carp );
27
27
28
sub new {
28
sub new {
29
    my ( $class, $data_array_ref ) = @_;
29
    my ( $class, $data_array_ref ) = @_;
(-)a/Koha/Edifact/Order.pm (-4 / +3 lines)
Lines 21-32 use utf8; Link Here
21
# You should have received a copy of the GNU General Public License
21
# You should have received a copy of the GNU General Public License
22
# along with Koha; if not, see <http://www.gnu.org/licenses>.
22
# along with Koha; if not, see <http://www.gnu.org/licenses>.
23
23
24
use Carp;
24
use Carp qw( carp );
25
use DateTime;
25
use DateTime;
26
use Readonly;
26
use Readonly qw( Readonly );
27
use Business::ISBN;
28
use Koha::Database;
27
use Koha::Database;
29
use Koha::DateUtils;
28
use Koha::DateUtils qw( dt_from_string );
30
use C4::Budgets qw( GetBudget );
29
use C4::Budgets qw( GetBudget );
31
30
32
use Koha::Acquisition::Orders;
31
use Koha::Acquisition::Orders;
(-)a/Koha/Edifact/Transport.pm (-5 / +4 lines)
Lines 21-35 use strict; Link Here
21
use warnings;
21
use warnings;
22
use utf8;
22
use utf8;
23
use DateTime;
23
use DateTime;
24
use Carp;
24
use Carp qw( carp );
25
use English qw{ -no_match_vars };
25
use English qw{ -no_match_vars };
26
use Net::FTP;
26
use Net::FTP;
27
use Net::SFTP::Foreign;
27
use Net::SFTP::Foreign;
28
use File::Slurp;
28
use File::Slurp qw( read_file );
29
use File::Copy;
29
use File::Copy qw( copy move );
30
use File::Basename qw( fileparse );
31
use Koha::Database;
30
use Koha::Database;
32
use Koha::DateUtils;
31
use Koha::DateUtils qw( dt_from_string );
33
use Encode qw( from_to );
32
use Encode qw( from_to );
34
33
35
sub new {
34
sub new {
(-)a/Koha/Email.pm (-1 / +1 lines)
Lines 22-28 use Modern::Perl; Link Here
22
22
23
use Email::Valid;
23
use Email::Valid;
24
use Email::MessageID;
24
use Email::MessageID;
25
use List::Util qw(pairs);
25
use List::Util qw( pairs );
26
26
27
use Koha::Exceptions;
27
use Koha::Exceptions;
28
28
(-)a/Koha/Exporter/Record.pm (-2 / +2 lines)
Lines 5-15 use MARC::File::XML; Link Here
5
use MARC::File::USMARC;
5
use MARC::File::USMARC;
6
6
7
use C4::AuthoritiesMarc;
7
use C4::AuthoritiesMarc;
8
use C4::Biblio qw( RemoveAllNsb GetMarcBiblio EmbedItemsInMarcBiblio GetMarcFromKohaField );
8
use C4::Biblio qw( GetMarcFromKohaField );
9
use C4::Record;
9
use C4::Record;
10
use Koha::CsvProfiles;
10
use Koha::CsvProfiles;
11
use Koha::Logger;
11
use Koha::Logger;
12
use List::Util qw(all any);
12
use List::Util qw( all any );
13
13
14
sub _get_record_for_export {
14
sub _get_record_for_export {
15
    my ($params)           = @_;
15
    my ($params)           = @_;
(-)a/Koha/ExternalContent.pm (-2 / +2 lines)
Lines 18-30 Link Here
18
package Koha::ExternalContent;
18
package Koha::ExternalContent;
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Carp;
21
use Carp qw( croak );
22
use base qw(Class::Accessor);
22
use base qw(Class::Accessor);
23
23
24
use Koha;
24
use Koha;
25
use Koha::Logger;
25
use Koha::Logger;
26
use Koha::Patrons;
26
use Koha::Patrons;
27
use C4::Auth qw( get_session );
27
use C4::Auth ();
28
28
29
__PACKAGE__->mk_accessors(qw(client koha_session_id koha_patron logger));
29
__PACKAGE__->mk_accessors(qw(client koha_session_id koha_patron logger));
30
30
(-)a/Koha/ExternalContent/OverDrive.pm (-1 / +1 lines)
Lines 18-24 Link Here
18
package Koha::ExternalContent::OverDrive;
18
package Koha::ExternalContent::OverDrive;
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Carp;
21
use Carp qw( croak );
22
22
23
use base qw(Koha::ExternalContent);
23
use base qw(Koha::ExternalContent);
24
use WebService::ILS::OverDrive::Patron;
24
use WebService::ILS::OverDrive::Patron;
(-)a/Koha/ExternalContent/RecordedBooks.pm (-1 / +1 lines)
Lines 18-24 Link Here
18
package Koha::ExternalContent::RecordedBooks;
18
package Koha::ExternalContent::RecordedBooks;
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use Carp;
21
use Carp qw( croak );
22
22
23
use base qw(Koha::ExternalContent);
23
use base qw(Koha::ExternalContent);
24
use WebService::ILS::RecordedBooks::PartnerPatron;
24
use WebService::ILS::RecordedBooks::PartnerPatron;
(-)a/Koha/Filter/MARC/EmbedItems.pm (-1 / +1 lines)
Lines 52-58 Filter to embed items information into MARC::Record objects. Link Here
52
52
53
use Modern::Perl;
53
use Modern::Perl;
54
54
55
use C4::Biblio;
55
use C4::Biblio ();
56
56
57
use base qw(Koha::RecordProcessor::Base);
57
use base qw(Koha::RecordProcessor::Base);
58
our $NAME = 'EmbedItems';
58
our $NAME = 'EmbedItems';
(-)a/Koha/Filter/MARC/EmbedItemsAvailability.pm (-1 / +1 lines)
Lines 32-38 Filter to embed items not on loan count information into MARC records. Link Here
32
32
33
use Modern::Perl;
33
use Modern::Perl;
34
34
35
use C4::Biblio qw/GetMarcFromKohaField/;
35
use C4::Biblio qw( GetMarcFromKohaField );
36
use Koha::Items;
36
use Koha::Items;
37
37
38
use base qw(Koha::RecordProcessor::Base);
38
use base qw(Koha::RecordProcessor::Base);
(-)a/Koha/Filter/MARC/EmbedSeeFromHeadings.pm (-2 / +1 lines)
Lines 32-40 Filter to embed see from headings into MARC records. Link Here
32
32
33
use strict;
33
use strict;
34
use warnings;
34
use warnings;
35
use Carp;
36
use Koha::MetadataRecord::Authority;
35
use Koha::MetadataRecord::Authority;
37
use C4::Biblio qw/GetMarcFromKohaField/;
36
use C4::Biblio qw( GetMarcFromKohaField );
38
37
39
use base qw(Koha::RecordProcessor::Base);
38
use base qw(Koha::RecordProcessor::Base);
40
our $NAME = 'EmbedSeeFromHeadings';
39
our $NAME = 'EmbedSeeFromHeadings';
(-)a/Koha/Filter/MARC/Null.pm (-1 lines)
Lines 33-39 RecordProcessor. Link Here
33
33
34
use strict;
34
use strict;
35
use warnings;
35
use warnings;
36
use Carp;
37
36
38
use base qw(Koha::RecordProcessor::Base);
37
use base qw(Koha::RecordProcessor::Base);
39
our $NAME = 'Null';
38
our $NAME = 'Null';
(-)a/Koha/Filter/MARC/ViewPolicy.pm (-1 lines)
Lines 39-45 menu. Link Here
39
=cut
39
=cut
40
40
41
use Modern::Perl;
41
use Modern::Perl;
42
use Carp;
43
use C4::Biblio qw( GetMarcStructure );
42
use C4::Biblio qw( GetMarcStructure );
44
43
45
use base qw(Koha::RecordProcessor::Base);
44
use base qw(Koha::RecordProcessor::Base);
(-)a/Koha/Hold.pm (-5 / +4 lines)
Lines 20-35 package Koha::Hold; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
22
23
use Carp;
23
use Data::Dumper qw( Dumper );
24
use Data::Dumper qw(Dumper);
24
use List::MoreUtils qw( any );
25
use List::MoreUtils qw(any);
26
25
27
use C4::Context qw(preference);
26
use C4::Context qw(preference);
28
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
27
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
29
use C4::Log;
28
use C4::Log qw( logaction );
30
29
31
use Koha::AuthorisedValues;
30
use Koha::AuthorisedValues;
32
use Koha::DateUtils qw(dt_from_string output_pref);
31
use Koha::DateUtils qw( dt_from_string );
33
use Koha::Patrons;
32
use Koha::Patrons;
34
use Koha::Biblios;
33
use Koha::Biblios;
35
use Koha::Items;
34
use Koha::Items;
(-)a/Koha/Holds.pm (-1 lines)
Lines 19-25 package Koha::Holds; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/I18N.pm (-4 / +3 lines)
Lines 19-32 package Koha::I18N; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use CGI;
22
use C4::Languages ();
23
use C4::Languages qw( getlanguage );
24
use C4::Context;
23
use C4::Context;
25
24
26
use Encode;
25
use Encode ();
27
use List::Util qw( first );
26
use List::Util qw( first );
28
use Locale::Messages qw(:locale_h LC_MESSAGES);
27
use Locale::Messages qw(:locale_h LC_MESSAGES);
29
use POSIX qw( setlocale );
28
use POSIX ();
30
use Koha::Cache::Memory::Lite;
29
use Koha::Cache::Memory::Lite;
31
30
32
use parent 'Exporter';
31
use parent 'Exporter';
(-)a/Koha/Illrequest.pm (-7 / +5 lines)
Lines 19-34 package Koha::Illrequest; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Clone 'clone';
22
use Clone qw( clone );
23
use File::Basename qw( basename );
23
use Try::Tiny qw( catch try );
24
use Encode qw( encode );
25
use Try::Tiny;
26
use DateTime;
24
use DateTime;
27
25
28
use C4::Letters qw( EnqueueLetter GetPreparedLetter );
26
use C4::Letters ();
29
use C4::Members;
27
use C4::Members ();
30
use Koha::Database;
28
use Koha::Database;
31
use Koha::DateUtils qw/ dt_from_string /;
29
use Koha::DateUtils qw( dt_from_string );
32
use Koha::Exceptions::Ill;
30
use Koha::Exceptions::Ill;
33
use Koha::Illcomments;
31
use Koha::Illcomments;
34
use Koha::Illrequestattributes;
32
use Koha::Illrequestattributes;
(-)a/Koha/Illrequest/Availability.pm (-1 / +1 lines)
Lines 19-25 package Koha::Illrequest::Availability; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use JSON;
22
use JSON ();
23
use MIME::Base64 qw( encode_base64 );
23
use MIME::Base64 qw( encode_base64 );
24
use URI::Escape qw( uri_escape );
24
use URI::Escape qw( uri_escape );
25
use Encode qw( encode );
25
use Encode qw( encode );
(-)a/Koha/Illrequest/Config.pm (-1 / +1 lines)
Lines 19-25 package Koha::Illrequest::Config; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use File::Basename qw/basename/;
22
use File::Basename qw( basename );
23
23
24
use C4::Context;
24
use C4::Context;
25
25
(-)a/Koha/Illrequest/Logger.pm (-2 / +1 lines)
Lines 18-25 package Koha::Illrequest::Logger; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use JSON qw( to_json from_json );
21
use JSON qw( from_json to_json );
22
use Time::Local;
23
22
24
use C4::Koha qw( GetAuthorisedValues );
23
use C4::Koha qw( GetAuthorisedValues );
25
use C4::Context;
24
use C4::Context;
(-)a/Koha/Indexer/Utils.pm (-1 / +1 lines)
Lines 20-26 use strict; Link Here
20
use warnings;
20
use warnings;
21
use 5.010;
21
use 5.010;
22
22
23
use XML::LibXML;
23
use XML::LibXML ();
24
24
25
=head1 Koha::Indexer::Utils
25
=head1 Koha::Indexer::Utils
26
26
(-)a/Koha/Item.pm (-5 / +3 lines)
Lines 19-35 package Koha::Item; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
22
use List::MoreUtils qw( any );
23
use List::MoreUtils qw(any);
23
use Data::Dumper qw( Dumper );
24
use Data::Dumper;
25
use Try::Tiny;
26
24
27
use Koha::Database;
25
use Koha::Database;
28
use Koha::DateUtils qw( dt_from_string );
26
use Koha::DateUtils qw( dt_from_string );
29
27
30
use C4::Context;
28
use C4::Context;
31
use C4::Circulation qw( GetBranchItemRule );
29
use C4::Circulation qw( GetBranchItemRule );
32
use C4::Reserves qw( GetReservesControlBranch );
30
use C4::Reserves ();
33
use C4::ClassSource qw( GetClassSort );
31
use C4::ClassSource qw( GetClassSort );
34
use C4::Log qw( logaction );
32
use C4::Log qw( logaction );
35
33
(-)a/Koha/Item/Transfer.pm (-3 / +1 lines)
Lines 17-28 package Koha::Item::Transfer; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
22
use C4::Items qw( CartToShelf ModDateLastSeen );
20
use C4::Items qw( CartToShelf ModDateLastSeen );
23
21
24
use Koha::Database;
22
use Koha::Database;
25
use Koha::DateUtils;
23
use Koha::DateUtils qw( dt_from_string );
26
use Koha::Exceptions::Item::Transfer;
24
use Koha::Exceptions::Item::Transfer;
27
25
28
use base qw(Koha::Object);
26
use base qw(Koha::Object);
(-)a/Koha/Item/Transfer/Limit.pm (-1 lines)
Lines 18-24 package Koha::Item::Transfer::Limit; Link Here
18
18
19
use Modern::Perl;
19
use Modern::Perl;
20
20
21
use Carp;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
23
(-)a/Koha/Item/Transfers.pm (-1 lines)
Lines 17-23 package Koha::Item::Transfers; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/ItemType.pm (-2 / +1 lines)
Lines 17-26 package Koha::ItemType; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use C4::Koha qw( getitemtypeimagelocation );
21
use C4::Koha qw( getitemtypeimagelocation );
23
use C4::Languages qw( getlanguage );
22
use C4::Languages ();
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::CirculationRules;
24
use Koha::CirculationRules;
26
use Koha::Localizations;
25
use Koha::Localizations;
(-)a/Koha/ItemTypes.pm (-2 / +1 lines)
Lines 17-25 package Koha::ItemTypes; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use C4::Languages qw( getlanguage );
21
use C4::Languages ();
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::ItemType;
24
use Koha::ItemType;
(-)a/Koha/Items.pm (-1 lines)
Lines 19-25 package Koha::Items; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/KeyboardShortcut.pm (-1 lines)
Lines 17-23 package Koha::KeyboardShortcut; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/KeyboardShortcuts.pm (-1 lines)
Lines 17-23 package Koha::KeyboardShortcuts; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Libraries.pm (-1 lines)
Lines 19-25 package Koha::Libraries; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use C4::Context;
23
use C4::Context;
25
24
(-)a/Koha/Library.pm (-1 lines)
Lines 19-25 package Koha::Library; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use C4::Context;
23
use C4::Context;
25
24
(-)a/Koha/Library/Group.pm (-2 / +1 lines)
Lines 19-28 package Koha::Library::Group; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::DateUtils qw(dt_from_string);
24
use Koha::DateUtils qw( dt_from_string );
26
use Koha::Libraries;
25
use Koha::Libraries;
27
26
28
use base qw(Koha::Object);
27
use base qw(Koha::Object);
(-)a/Koha/Library/Groups.pm (-1 lines)
Lines 19-25 package Koha::Library::Groups; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Library/OverDriveInfo.pm (-1 lines)
Lines 17-23 package Koha::Library::OverDriveInfo; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Library/OverDriveInfos.pm (-1 lines)
Lines 17-23 package Koha::Library::OverDriveInfos; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Linktracker.pm (-1 lines)
Lines 32-38 Koha::Linktracker Link Here
32
=cut
32
=cut
33
33
34
use Modern::Perl;
34
use Modern::Perl;
35
use Carp;
36
use C4::Context;
35
use C4::Context;
37
use base qw(Class::Accessor);
36
use base qw(Class::Accessor);
38
37
(-)a/Koha/List/Patron.pm (-1 / +1 lines)
Lines 27-33 Koha::List::Patron - Management of lists of patrons Link Here
27
27
28
use Modern::Perl;
28
use Modern::Perl;
29
29
30
use Carp;
30
use Carp qw( carp croak );
31
31
32
use Koha::Database;
32
use Koha::Database;
33
33
(-)a/Koha/Logger.pm (-1 lines)
Lines 37-43 Koha::Logger Link Here
37
use Modern::Perl;
37
use Modern::Perl;
38
38
39
use Log::Log4perl;
39
use Log::Log4perl;
40
use Carp;
41
40
42
use C4::Context;
41
use C4::Context;
43
42
(-)a/Koha/MarcSubfieldStructure.pm (-1 lines)
Lines 17-23 package Koha::MarcSubfieldStructure; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/MarcSubfieldStructures.pm (-1 lines)
Lines 17-23 package Koha::MarcSubfieldStructures; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/MessageAttribute.pm (-1 lines)
Lines 19-25 package Koha::MessageAttribute; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use base qw(Koha::Object);
23
use base qw(Koha::Object);
25
24
(-)a/Koha/MessageAttributes.pm (-1 lines)
Lines 19-25 package Koha::MessageAttributes; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use base qw(Koha::Objects);
23
use base qw(Koha::Objects);
25
use Koha::MessageAttribute;
24
use Koha::MessageAttribute;
(-)a/Koha/MetaSearcher.pm (-2 / +2 lines)
Lines 29-37 use Koha::Caches; Link Here
29
use Koha::Database;
29
use Koha::Database;
30
use Koha::MetadataRecord;
30
use Koha::MetadataRecord;
31
use MARC::File::XML;
31
use MARC::File::XML;
32
use Storable qw( store_fd fd_retrieve );
32
use Storable qw( fd_retrieve store_fd );
33
use Time::HiRes qw( clock_gettime CLOCK_MONOTONIC );
33
use Time::HiRes qw( clock_gettime CLOCK_MONOTONIC );
34
use UUID;
34
use UUID ();
35
use ZOOM;
35
use ZOOM;
36
36
37
use sort 'stable';
37
use sort 'stable';
(-)a/Koha/MetadataRecord.pm (-2 / +2 lines)
Lines 34-41 and authority) records in Koha. Link Here
34
34
35
use Modern::Perl;
35
use Modern::Perl;
36
36
37
use Carp;
37
use Carp qw( carp );
38
use C4::Biblio qw( TransformMarcToKoha TransformMarcToKohaOneField );
38
use C4::Biblio ();
39
use Koha::Util::MARC;
39
use Koha::Util::MARC;
40
40
41
use base qw(Class::Accessor);
41
use base qw(Class::Accessor);
(-)a/Koha/MetadataRecord/Authority.pm (-2 / +1 lines)
Lines 33-41 Authority data. Link Here
33
33
34
use strict;
34
use strict;
35
use warnings;
35
use warnings;
36
use Carp;
37
use C4::Context;
36
use C4::Context;
38
use MARC::Record;
37
use MARC::Record ();
39
use MARC::File::XML;
38
use MARC::File::XML;
40
use C4::Charset qw( StripNonXmlChars );
39
use C4::Charset qw( StripNonXmlChars );
41
use Koha::Util::MARC;
40
use Koha::Util::MARC;
(-)a/Koha/Middleware/RealIP.pm (-2 / +1 lines)
Lines 23-30 use parent qw(Plack::Middleware); Link Here
23
23
24
use C4::Context;
24
use C4::Context;
25
25
26
use Net::Netmask;
26
use Net::Netmask ();
27
use Plack::Util::Accessor qw( trusted_proxy );
28
27
29
=head1 METHODS
28
=head1 METHODS
30
29
(-)a/Koha/News.pm (-1 lines)
Lines 19-25 package Koha::News; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/NewsItem.pm (-1 lines)
Lines 19-25 package Koha::NewsItem; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Patrons;
24
use Koha::Patrons;
(-)a/Koha/Notice/Message.pm (-1 lines)
Lines 17-23 package Koha::Notice::Message; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Notice/Messages.pm (-1 lines)
Lines 17-23 package Koha::Notice::Messages; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Notice/Template.pm (-1 lines)
Lines 17-23 package Koha::Notice::Template; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Notice/Templates.pm (-1 lines)
Lines 17-23 package Koha::Notice::Templates; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Number/Price.pm (-1 / +1 lines)
Lines 19-25 package Koha::Number::Price; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Number::Format;
22
use Number::Format ();
23
use C4::Context;
23
use C4::Context;
24
use Koha::Acquisition::Currencies;
24
use Koha::Acquisition::Currencies;
25
25
(-)a/Koha/OAI/Server/GetRecord.pm (-2 / +1 lines)
Lines 20-27 package Koha::OAI::Server::GetRecord; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
use HTTP::OAI;
22
use HTTP::OAI;
23
use C4::Biblio;
23
use C4::OAI::Sets qw( GetOAISetsBiblio );
24
use C4::OAI::Sets;
25
use MARC::File::XML;
24
use MARC::File::XML;
26
25
27
use base ("HTTP::OAI::GetRecord");
26
use base ("HTTP::OAI::GetRecord");
(-)a/Koha/OAI/Server/ListBase.pm (-2 / +1 lines)
Lines 28-39 Koha::OAI::Server::ListBase contains OAI-PMH functions shared by ListIdentifiers Link Here
28
=cut
28
=cut
29
29
30
use Modern::Perl;
30
use Modern::Perl;
31
use C4::Biblio;
32
use HTTP::OAI;
31
use HTTP::OAI;
33
use Koha::OAI::Server::ResumptionToken;
32
use Koha::OAI::Server::ResumptionToken;
34
use Koha::OAI::Server::Record;
33
use Koha::OAI::Server::Record;
35
use Koha::OAI::Server::DeletedRecord;
34
use Koha::OAI::Server::DeletedRecord;
36
use C4::OAI::Sets;
35
use C4::OAI::Sets qw( GetOAISetBySpec GetOAISetsBiblio );
37
use MARC::File::XML;
36
use MARC::File::XML;
38
37
39
sub GetRecords {
38
sub GetRecords {
(-)a/Koha/OAI/Server/ListSets.pm (-1 / +1 lines)
Lines 22-28 use Modern::Perl; Link Here
22
use HTTP::OAI;
22
use HTTP::OAI;
23
use Koha::OAI::Server::ResumptionToken;
23
use Koha::OAI::Server::ResumptionToken;
24
use Koha::OAI::Server::Description;
24
use Koha::OAI::Server::Description;
25
use C4::OAI::Sets;
25
use C4::OAI::Sets qw( GetOAISets );
26
26
27
use base ("HTTP::OAI::ListSets");
27
use base ("HTTP::OAI::ListSets");
28
28
(-)a/Koha/OAI/Server/Record.pm (-1 / +1 lines)
Lines 21-27 package Koha::OAI::Server::Record; Link Here
21
use Modern::Perl;
21
use Modern::Perl;
22
use HTTP::OAI;
22
use HTTP::OAI;
23
use HTTP::OAI::Metadata::OAI_DC;
23
use HTTP::OAI::Metadata::OAI_DC;
24
use XML::LibXML;
24
use XML::LibXML ();
25
25
26
use base ("HTTP::OAI::Record");
26
use base ("HTTP::OAI::Record");
27
27
(-)a/Koha/OAI/Server/Repository.pm (-2 / +2 lines)
Lines 32-41 use Koha::OAI::Server::GetRecord; Link Here
32
use Koha::OAI::Server::ListRecords;
32
use Koha::OAI::Server::ListRecords;
33
use Koha::OAI::Server::ListIdentifiers;
33
use Koha::OAI::Server::ListIdentifiers;
34
use XML::SAX::Writer;
34
use XML::SAX::Writer;
35
use YAML::XS;
35
use YAML::XS ();
36
use CGI qw/:standard -oldstyle_urls/;
36
use CGI qw/:standard -oldstyle_urls/;
37
use C4::Context;
37
use C4::Context;
38
use C4::Biblio;
38
use C4::Biblio qw( GetMarcBiblio );
39
use Koha::XSLT::Base;
39
use Koha::XSLT::Base;
40
40
41
=head1 NAME
41
=head1 NAME
(-)a/Koha/Object.pm (-4 / +4 lines)
Lines 20-33 package Koha::Object; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
22
23
use Carp;
23
use Carp qw( croak );
24
use Mojo::JSON;
24
use Mojo::JSON ();
25
use Scalar::Util qw( blessed looks_like_number );
25
use Scalar::Util qw( blessed looks_like_number );
26
use Try::Tiny;
26
use Try::Tiny qw( catch try );
27
27
28
use Koha::Database;
28
use Koha::Database;
29
use Koha::Exceptions::Object;
29
use Koha::Exceptions::Object;
30
use Koha::DateUtils;
30
use Koha::DateUtils qw( dt_from_string output_pref );
31
use Koha::Object::Message;
31
use Koha::Object::Message;
32
32
33
=head1 NAME
33
=head1 NAME
(-)a/Koha/Object/Limit/Library.pm (-1 / +1 lines)
Lines 21-27 use Koha::Database; Link Here
21
use Koha::Exceptions;
21
use Koha::Exceptions;
22
use Koha::Libraries;
22
use Koha::Libraries;
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
=head1 NAME
26
=head1 NAME
27
27
(-)a/Koha/Objects.pm (-1 / +1 lines)
Lines 19-25 package Koha::Objects; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
22
use Carp qw( carp );
23
use List::MoreUtils qw( none );
23
use List::MoreUtils qw( none );
24
use Class::Inspector;
24
use Class::Inspector;
25
25
(-)a/Koha/Old/Holds.pm (-1 lines)
Lines 19-25 package Koha::Old::Holds; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Patron.pm (-7 / +6 lines)
Lines 20-46 package Koha::Patron; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
22
23
use Carp;
24
use List::MoreUtils qw( any uniq );
23
use List::MoreUtils qw( any uniq );
25
use JSON qw( to_json );
24
use JSON qw( to_json );
26
use Unicode::Normalize;
25
use Unicode::Normalize qw( NFKD );
27
26
28
use C4::Context;
27
use C4::Context;
29
use C4::Log;
28
use C4::Log qw( logaction );
30
use Koha::Account;
29
use Koha::Account;
31
use Koha::ArticleRequests;
30
use Koha::ArticleRequests;
32
use C4::Letters qw( GetPreparedLetter EnqueueLetter );
31
use C4::Letters ();
33
use Koha::AuthUtils qw( hash_password is_password_valid );
32
use Koha::AuthUtils ();
34
use Koha::Checkouts;
33
use Koha::Checkouts;
35
use Koha::Club::Enrollments;
34
use Koha::Club::Enrollments;
36
use Koha::Database;
35
use Koha::Database;
37
use Koha::DateUtils;
36
use Koha::DateUtils qw( dt_from_string );
38
use Koha::Exceptions::Password;
37
use Koha::Exceptions::Password;
39
use Koha::Holds;
38
use Koha::Holds;
40
use Koha::Old::Checkouts;
39
use Koha::Old::Checkouts;
41
use Koha::Patron::Attributes;
40
use Koha::Patron::Attributes;
42
use Koha::Patron::Categories;
41
use Koha::Patron::Categories;
43
use Koha::Patron::Debarments;
42
use Koha::Patron::Debarments ();
44
use Koha::Patron::HouseboundProfile;
43
use Koha::Patron::HouseboundProfile;
45
use Koha::Patron::HouseboundRole;
44
use Koha::Patron::HouseboundRole;
46
use Koha::Patron::Images;
45
use Koha::Patron::Images;
(-)a/Koha/Patron/Category.pm (-3 / +2 lines)
Lines 17-29 package Koha::Patron::Category; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
20
use List::MoreUtils qw( any );
21
use List::MoreUtils qw(any);
22
21
23
use C4::Members::Messaging;
22
use C4::Members::Messaging;
24
23
25
use Koha::Database;
24
use Koha::Database;
26
use Koha::DateUtils;
25
use Koha::DateUtils qw( dt_from_string );
27
26
28
use base qw(Koha::Object Koha::Object::Limit::Library);
27
use base qw(Koha::Object Koha::Object::Limit::Library);
29
28
(-)a/Koha/Patron/Discharge.pm (-3 / +3 lines)
Lines 1-9 Link Here
1
package Koha::Patron::Discharge;
1
package Koha::Patron::Discharge;
2
2
3
use Modern::Perl;
3
use Modern::Perl;
4
use CGI;
4
use CGI ();
5
use File::Temp qw( :POSIX );
5
use File::Temp qw( :POSIX );
6
use Carp;
6
use Carp qw( carp );
7
7
8
use C4::Templates qw ( gettemplate );
8
use C4::Templates qw ( gettemplate );
9
use C4::Letters qw( GetPreparedLetter );
9
use C4::Letters qw( GetPreparedLetter );
Lines 11-17 use C4::Letters qw( GetPreparedLetter ); Link Here
11
use Koha::Database;
11
use Koha::Database;
12
use Koha::DateUtils qw( dt_from_string output_pref );
12
use Koha::DateUtils qw( dt_from_string output_pref );
13
use Koha::Patrons;
13
use Koha::Patrons;
14
use Koha::Patron::Debarments;
14
use Koha::Patron::Debarments ();
15
15
16
sub count {
16
sub count {
17
    my ($params) = @_;
17
    my ($params) = @_;
(-)a/Koha/Patron/Image.pm (-1 lines)
Lines 17-23 package Koha::Patron::Image; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Patron/Images.pm (-1 lines)
Lines 17-23 package Koha::Patron::Images; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Patron/Message.pm (-2 / +1 lines)
Lines 17-26 package Koha::Patron::Message; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use C4::Context;
21
use C4::Context;
23
use C4::Log qw( logaction );
22
use C4::Log ();
24
23
25
use Koha::Database;
24
use Koha::Database;
26
25
(-)a/Koha/Patron/Messages.pm (-1 lines)
Lines 17-23 package Koha::Patron::Messages; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Patron/Modification.pm (-4 / +3 lines)
Lines 19-25 package Koha::Patron::Modification; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Exceptions::Patron::Modification;
24
use Koha::Exceptions::Patron::Modification;
Lines 27-35 use Koha::Patron::Attribute; Link Here
27
use Koha::Patron::Attributes;
26
use Koha::Patron::Attributes;
28
use Koha::Patron::Modifications;
27
use Koha::Patron::Modifications;
29
28
30
use JSON;
29
use JSON qw( from_json );
31
use List::MoreUtils qw( uniq any );
30
use List::MoreUtils qw( any uniq );
32
use Try::Tiny;
31
use Try::Tiny qw( catch try );
33
32
34
use base qw(Koha::Object);
33
use base qw(Koha::Object);
35
34
(-)a/Koha/Patron/Modifications.pm (-2 / +2 lines)
Lines 29-36 use C4::Context; Link Here
29
use Koha::Patron::Attribute;
29
use Koha::Patron::Attribute;
30
use Koha::Patron::Modification;
30
use Koha::Patron::Modification;
31
31
32
use JSON;
32
use JSON qw( from_json );
33
use List::Util qw /any none/;
33
use List::Util qw( none );
34
34
35
use base qw(Koha::Objects);
35
use base qw(Koha::Objects);
36
36
(-)a/Koha/Patron/Password/Recovery.pm (-2 / +2 lines)
Lines 20-27 package Koha::Patron::Password::Recovery; Link Here
20
use Modern::Perl;
20
use Modern::Perl;
21
use C4::Context;
21
use C4::Context;
22
use C4::Letters;
22
use C4::Letters;
23
use Crypt::Eksblowfish::Bcrypt qw(en_base64);
23
use Crypt::Eksblowfish::Bcrypt qw( en_base64 );
24
use Koha::DateUtils;
24
use Koha::DateUtils qw( dt_from_string );
25
25
26
our (@ISA, @EXPORT_OK);
26
our (@ISA, @EXPORT_OK);
27
BEGIN {
27
BEGIN {
(-)a/Koha/Patron/Relationship.pm (-2 / +1 lines)
Lines 17-25 package Koha::Patron::Relationship; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
use List::MoreUtils qw( any );
20
use List::MoreUtils qw( any );
22
use Try::Tiny;
21
use Try::Tiny qw( catch try );
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Exceptions::Patron::Relationship;
24
use Koha::Exceptions::Patron::Relationship;
(-)a/Koha/Patron/Relationships.pm (-1 lines)
Lines 17-23 package Koha::Patron::Relationships; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
use List::MoreUtils qw( uniq );
20
use List::MoreUtils qw( uniq );
22
21
23
use Koha::Database;
22
use Koha::Database;
(-)a/Koha/Patrons.pm (-3 / +1 lines)
Lines 20-36 package Koha::Patrons; Link Here
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
22
23
use Carp;
24
23
25
use Koha::Database;
24
use Koha::Database;
26
use Koha::DateUtils;
25
use Koha::DateUtils qw( dt_from_string );
27
26
28
use Koha::ArticleRequests;
27
use Koha::ArticleRequests;
29
use Koha::ArticleRequest::Status;
28
use Koha::ArticleRequest::Status;
30
use Koha::Patron;
29
use Koha::Patron;
31
use Koha::Exceptions::Patron;
30
use Koha::Exceptions::Patron;
32
use Koha::Patron::Categories;
31
use Koha::Patron::Categories;
33
use Date::Calc qw( Today Add_Delta_YMD );
34
32
35
use base qw(Koha::Objects);
33
use base qw(Koha::Objects);
36
34
(-)a/Koha/Patrons/Import.pm (-5 / +4 lines)
Lines 17-36 package Koha::Patrons::Import; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use Moo;
19
use Moo;
20
use namespace::clean;
21
20
22
use Carp;
21
use Carp qw( carp );
23
use Text::CSV;
22
use Text::CSV;
24
use Encode qw( decode_utf8 );
23
use Encode qw( decode_utf8 );
25
use Try::Tiny;
24
use Try::Tiny qw( catch try );
26
25
27
use C4::Members qw( checkcardnumber );
26
use C4::Members qw( checkcardnumber );
28
27
29
use Koha::Libraries;
28
use Koha::Libraries;
30
use Koha::Patrons;
29
use Koha::Patrons;
31
use Koha::Patron::Categories;
30
use Koha::Patron::Categories;
32
use Koha::Patron::Debarments;
31
use Koha::Patron::Debarments qw( AddDebarment GetDebarments );
33
use Koha::DateUtils;
32
use Koha::DateUtils qw( dt_from_string output_pref );
34
33
35
=head1 NAME
34
=head1 NAME
36
35
(-)a/Koha/Plugins.pm (-5 / +4 lines)
Lines 19-30 package Koha::Plugins; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Array::Utils qw(array_minus);
22
use Array::Utils qw( array_minus );
23
use Class::Inspector;
23
use Class::Inspector;
24
use List::MoreUtils qw(any);
24
use List::MoreUtils qw( any );
25
use Module::Load::Conditional qw(can_load);
25
use Module::Load::Conditional qw( can_load );
26
use Module::Load qw(load);
26
use Module::Load ();
27
use Module::Pluggable search_path => ['Koha::Plugin'], except => qr/::Edifact(|::Line|::Message|::Order|::Segment|::Transport)$/;
28
27
29
use C4::Context;
28
use C4::Context;
30
use C4::Output;
29
use C4::Output;
(-)a/Koha/Plugins/Base.pm (-3 / +2 lines)
Lines 19-27 package Koha::Plugins::Base; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Module::Pluggable require => 1;
22
use Cwd qw( abs_path );
23
use Cwd qw(abs_path);
23
use List::Util qw( max );
24
use List::Util qw(max);
25
24
26
use base qw{Module::Bundled::Files};
25
use base qw{Module::Bundled::Files};
27
26
(-)a/Koha/Plugins/Handler.pm (-3 / +3 lines)
Lines 19-28 package Koha::Plugins::Handler; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Array::Utils qw(array_minus);
22
use Array::Utils qw( array_minus );
23
use File::Path qw(remove_tree);
23
use File::Path qw( remove_tree );
24
24
25
use Module::Load qw(load);
25
use Module::Load qw( load );
26
26
27
use C4::Context;
27
use C4::Context;
28
use Koha::Plugins::Methods;
28
use Koha::Plugins::Methods;
(-)a/Koha/Plugins/Method.pm (-1 lines)
Lines 17-23 package Koha::Plugins::Method; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Plugins/Methods.pm (-1 lines)
Lines 17-23 package Koha::Plugins::Methods; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/PseudonymizedTransaction.pm (-2 / +1 lines)
Lines 16-23 package Koha::PseudonymizedTransaction; Link Here
16
16
17
use Modern::Perl;
17
use Modern::Perl;
18
18
19
use Carp;
19
use Crypt::Eksblowfish::Bcrypt qw( bcrypt );
20
use Crypt::Eksblowfish::Bcrypt qw(bcrypt en_base64);
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Exceptions::Config;
22
use Koha::Exceptions::Config;
(-)a/Koha/PseudonymizedTransactions.pm (-1 lines)
Lines 16-22 package Koha::PseudonymizedTransactions; Link Here
16
16
17
use Modern::Perl;
17
use Modern::Perl;
18
18
19
use Carp;
20
19
21
use Koha::Database;
20
use Koha::Database;
22
use Koha::PseudonymizedTransaction;
21
use Koha::PseudonymizedTransaction;
(-)a/Koha/Quote.pm (-1 lines)
Lines 16-22 package Koha::Quote; Link Here
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use Carp;
20
19
21
use Koha::Database;
20
use Koha::Database;
22
use Koha::Quotes;
21
use Koha::Quotes;
(-)a/Koha/Quotes.pm (-2 / +1 lines)
Lines 16-25 package Koha::Quotes; Link Here
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
16
# along with Koha; if not, see <http://www.gnu.org/licenses>.
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
use Carp;
20
19
21
use Koha::Database;
20
use Koha::Database;
22
use Koha::DateUtils qw(dt_from_string);
21
use Koha::DateUtils qw( dt_from_string );
23
use Koha::Quote;
22
use Koha::Quote;
24
23
25
use base qw(Koha::Objects);
24
use base qw(Koha::Objects);
(-)a/Koha/RDF.pm (-1 / +1 lines)
Lines 18-24 package Koha::RDF; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use URI;
21
use URI ();
22
22
23
use C4::Context;
23
use C4::Context;
24
24
(-)a/Koha/REST/Plugin/Objects.pm (-1 / +1 lines)
Lines 19-25 use Modern::Perl; Link Here
19
19
20
use Mojo::Base 'Mojolicious::Plugin';
20
use Mojo::Base 'Mojolicious::Plugin';
21
21
22
use JSON;
22
use JSON ();
23
23
24
=head1 NAME
24
=head1 NAME
25
25
(-)a/Koha/REST/Plugin/PluginRoutes.pm (-2 / +2 lines)
Lines 23-30 use Koha::Exceptions::Plugin; Link Here
23
use Koha::Plugins;
23
use Koha::Plugins;
24
use Koha::Logger;
24
use Koha::Logger;
25
25
26
use Clone qw(clone);
26
use Clone qw( clone );
27
use Try::Tiny;
27
use Try::Tiny qw( catch try );
28
28
29
=head1 NAME
29
=head1 NAME
30
30
(-)a/Koha/REST/Plugin/Query.pm (-3 / +3 lines)
Lines 18-26 package Koha::REST::Plugin::Query; Link Here
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Mojo::Base 'Mojolicious::Plugin';
20
use Mojo::Base 'Mojolicious::Plugin';
21
use List::MoreUtils qw(any);
21
use List::MoreUtils qw( any );
22
use Scalar::Util qw(reftype);
22
use Scalar::Util qw( reftype );
23
use JSON qw(decode_json);
23
use JSON qw( decode_json );
24
24
25
use Koha::Exceptions;
25
use Koha::Exceptions;
26
26
(-)a/Koha/REST/V1.pm (-1 / +1 lines)
Lines 23-29 use C4::Context; Link Here
23
use Koha::Logger;
23
use Koha::Logger;
24
24
25
use JSON::Validator::OpenAPI::Mojolicious;
25
use JSON::Validator::OpenAPI::Mojolicious;
26
use Try::Tiny;
26
use Try::Tiny qw( catch try );
27
27
28
=head1 NAME
28
=head1 NAME
29
29
(-)a/Koha/REST/V1/Acquisitions/Funds.pm (-1 / +1 lines)
Lines 21-27 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::Acquisition::Funds;
22
use Koha::Acquisition::Funds;
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
=head1 NAME
26
=head1 NAME
27
27
(-)a/Koha/REST/V1/Acquisitions/Orders.pm (-4 / +2 lines)
Lines 20-31 use Modern::Perl; Link Here
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use Koha::Acquisition::Orders;
22
use Koha::Acquisition::Orders;
23
use Koha::DateUtils;
24
23
25
use Clone 'clone';
24
use Clone qw( clone );
26
use JSON qw(decode_json);
27
use Scalar::Util qw( blessed );
25
use Scalar::Util qw( blessed );
28
use Try::Tiny;
26
use Try::Tiny qw( catch try );
29
27
30
=head1 NAME
28
=head1 NAME
31
29
(-)a/Koha/REST/V1/Acquisitions/Vendors.pm (-1 / +1 lines)
Lines 21-27 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::Acquisition::Booksellers;
22
use Koha::Acquisition::Booksellers;
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
=head1 NAME
26
=head1 NAME
27
27
(-)a/Koha/REST/V1/AdvancedEditorMacro.pm (-1 / +1 lines)
Lines 19-25 use Modern::Perl; Link Here
19
use Mojo::Base 'Mojolicious::Controller';
19
use Mojo::Base 'Mojolicious::Controller';
20
use Koha::AdvancedEditorMacros;
20
use Koha::AdvancedEditorMacros;
21
21
22
use Try::Tiny;
22
use Try::Tiny qw( catch try );
23
23
24
=head1 Name
24
=head1 Name
25
25
(-)a/Koha/REST/V1/Auth.pm (-3 / +3 lines)
Lines 38-47 use Koha::Exceptions; Link Here
38
use Koha::Exceptions::Authentication;
38
use Koha::Exceptions::Authentication;
39
use Koha::Exceptions::Authorization;
39
use Koha::Exceptions::Authorization;
40
40
41
use MIME::Base64;
41
use MIME::Base64 qw( decode_base64 );
42
use Module::Load::Conditional;
42
use Module::Load::Conditional ();
43
use Scalar::Util qw( blessed );
43
use Scalar::Util qw( blessed );
44
use Try::Tiny;
44
use Try::Tiny qw( catch try );
45
45
46
=head1 NAME
46
=head1 NAME
47
47
(-)a/Koha/REST/V1/Biblios.pm (-3 / +3 lines)
Lines 21-32 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::Biblios;
22
use Koha::Biblios;
23
use Koha::RecordProcessor;
23
use Koha::RecordProcessor;
24
use C4::Biblio qw(DelBiblio);
24
use C4::Biblio qw( DelBiblio );
25
25
26
use List::MoreUtils qw(any);
26
use List::MoreUtils qw( any );
27
use MARC::Record::MiJ;
27
use MARC::Record::MiJ;
28
28
29
use Try::Tiny;
29
use Try::Tiny qw( catch try );
30
30
31
=head1 API
31
=head1 API
32
32
(-)a/Koha/REST/V1/CashRegisters/Cashups.pm (-2 / +1 lines)
Lines 19-26 use Modern::Perl; Link Here
19
19
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use Scalar::Util qw(blessed);
22
use Try::Tiny qw( catch try );
23
use Try::Tiny;
24
23
25
use Koha::Cash::Registers;
24
use Koha::Cash::Registers;
26
25
(-)a/Koha/REST/V1/Checkouts.pm (-2 / +2 lines)
Lines 18-24 package Koha::REST::V1::Checkouts; Link Here
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
use Mojo::JSON;
21
use Mojo::JSON ();
22
22
23
use C4::Auth qw( haspermission );
23
use C4::Auth qw( haspermission );
24
use C4::Context;
24
use C4::Context;
Lines 26-32 use C4::Circulation; Link Here
26
use Koha::Checkouts;
26
use Koha::Checkouts;
27
use Koha::Old::Checkouts;
27
use Koha::Old::Checkouts;
28
28
29
use Try::Tiny;
29
use Try::Tiny qw( catch try );
30
30
31
=head1 NAME
31
=head1 NAME
32
32
(-)a/Koha/REST/V1/CirculationRules.pm (-1 lines)
Lines 21-27 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::CirculationRules;
22
use Koha::CirculationRules;
23
23
24
use Try::Tiny;
25
24
26
=head1 API
25
=head1 API
27
26
(-)a/Koha/REST/V1/Cities.pm (-1 / +1 lines)
Lines 21-27 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::Cities;
22
use Koha::Cities;
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
=head1 API
26
=head1 API
27
27
(-)a/Koha/REST/V1/Clubs/Holds.pm (-5 / +3 lines)
Lines 19-25 use Modern::Perl; Link Here
19
19
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use C4::Biblio;
23
use C4::Reserves;
22
use C4::Reserves;
24
23
25
use Koha::Items;
24
use Koha::Items;
Lines 27-37 use Koha::Patrons; Link Here
27
use Koha::Holds;
26
use Koha::Holds;
28
use Koha::Clubs;
27
use Koha::Clubs;
29
use Koha::Club::Hold;
28
use Koha::Club::Hold;
30
use Koha::DateUtils;
29
use Koha::DateUtils qw( dt_from_string output_pref );
31
30
32
use Scalar::Util qw(blessed);
31
use Scalar::Util qw( blessed );
33
use Try::Tiny;
32
use Try::Tiny qw( catch try );
34
use List::Util 'shuffle';
35
33
36
=head1 API
34
=head1 API
37
35
(-)a/Koha/REST/V1/Config/SMTP/Servers.pm (-1 / +1 lines)
Lines 21-27 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::SMTP::Servers;
22
use Koha::SMTP::Servers;
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
=head1 API
26
=head1 API
27
27
(-)a/Koha/REST/V1/Holds.pm (-5 / +4 lines)
Lines 19-36 use Modern::Perl; Link Here
19
19
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use Mojo::JSON qw(decode_json);
22
use Mojo::JSON ();
23
23
24
use C4::Biblio;
25
use C4::Reserves;
24
use C4::Reserves;
26
25
27
use Koha::Items;
26
use Koha::Items;
28
use Koha::Patrons;
27
use Koha::Patrons;
29
use Koha::Holds;
28
use Koha::Holds;
30
use Koha::DateUtils;
29
use Koha::DateUtils qw( dt_from_string output_pref );
31
30
32
use List::MoreUtils qw(any);
31
use List::MoreUtils qw( any );
33
use Try::Tiny;
32
use Try::Tiny qw( catch try );
34
33
35
=head1 API
34
=head1 API
36
35
(-)a/Koha/REST/V1/ImportBatchProfiles.pm (-1 / +1 lines)
Lines 22-28 use Mojo::Base 'Mojolicious::Controller'; Link Here
22
use Koha::ImportBatchProfiles;
22
use Koha::ImportBatchProfiles;
23
use Koha::ImportBatchProfile;
23
use Koha::ImportBatchProfile;
24
24
25
use Try::Tiny;
25
use Try::Tiny qw( catch try );
26
26
27
=head1 NAME
27
=head1 NAME
28
28
(-)a/Koha/REST/V1/Items.pm (-1 / +1 lines)
Lines 22-28 use Mojo::Base 'Mojolicious::Controller'; Link Here
22
use Koha::Items;
22
use Koha::Items;
23
23
24
use List::MoreUtils qw(any);
24
use List::MoreUtils qw(any);
25
use Try::Tiny;
25
use Try::Tiny qw( catch try );
26
26
27
=head1 NAME
27
=head1 NAME
28
28
(-)a/Koha/REST/V1/Libraries.pm (-1 / +1 lines)
Lines 22-28 use Koha::Libraries; Link Here
22
22
23
use Scalar::Util qw( blessed );
23
use Scalar::Util qw( blessed );
24
24
25
use Try::Tiny;
25
use Try::Tiny qw( catch try );
26
26
27
=head1 NAME
27
=head1 NAME
28
28
(-)a/Koha/REST/V1/OAuth.pm (-2 / +2 lines)
Lines 17-27 package Koha::REST::V1::OAuth; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Module::Load::Conditional;
20
use Module::Load::Conditional ();
21
21
22
use C4::Context;
22
use C4::Context;
23
use Koha::OAuth;
23
use Koha::OAuth;
24
use MIME::Base64;
24
use MIME::Base64 qw( decode_base64 );
25
25
26
use Mojo::Base 'Mojolicious::Controller';
26
use Mojo::Base 'Mojolicious::Controller';
27
27
(-)a/Koha/REST/V1/Patrons.pm (-3 / +2 lines)
Lines 20-30 use Modern::Perl; Link Here
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use Koha::Database;
22
use Koha::Database;
23
use Koha::DateUtils;
24
use Koha::Patrons;
23
use Koha::Patrons;
25
24
26
use Scalar::Util qw(blessed);
25
use Scalar::Util qw( blessed );
27
use Try::Tiny;
26
use Try::Tiny qw( catch try );
28
27
29
=head1 NAME
28
=head1 NAME
30
29
(-)a/Koha/REST/V1/Patrons/Account.pm (-2 / +1 lines)
Lines 21-28 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::Patrons;
22
use Koha::Patrons;
23
23
24
use Scalar::Util qw(blessed);
24
use Try::Tiny qw( catch try );
25
use Try::Tiny;
26
25
27
=head1 NAME
26
=head1 NAME
28
27
(-)a/Koha/REST/V1/Patrons/Attributes.pm (-2 / +2 lines)
Lines 22-29 use Mojo::Base 'Mojolicious::Controller'; Link Here
22
use Koha::Patron::Attributes;
22
use Koha::Patron::Attributes;
23
use Koha::Patrons;
23
use Koha::Patrons;
24
24
25
use Scalar::Util qw(blessed);
25
use Scalar::Util qw( blessed );
26
use Try::Tiny;
26
use Try::Tiny qw( catch try );
27
27
28
=head1 NAME
28
=head1 NAME
29
29
(-)a/Koha/REST/V1/Patrons/Password.pm (-2 / +2 lines)
Lines 23-30 use C4::Auth qw(checkpw_internal); Link Here
23
23
24
use Koha::Patrons;
24
use Koha::Patrons;
25
25
26
use Scalar::Util qw(blessed);
26
use Scalar::Util qw( blessed );
27
use Try::Tiny;
27
use Try::Tiny qw( catch try );
28
28
29
=head1 NAME
29
=head1 NAME
30
30
(-)a/Koha/REST/V1/Quotes.pm (-1 / +1 lines)
Lines 21-27 use Mojo::Base 'Mojolicious::Controller'; Link Here
21
21
22
use Koha::Quotes;
22
use Koha::Quotes;
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
=head1 API
26
=head1 API
27
27
(-)a/Koha/REST/V1/ReturnClaims.pm (-2 / +1 lines)
Lines 19-29 use Modern::Perl; Link Here
19
19
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use Try::Tiny;
22
use Try::Tiny qw( catch try );
23
23
24
use Koha::Checkouts::ReturnClaims;
24
use Koha::Checkouts::ReturnClaims;
25
use Koha::Checkouts;
25
use Koha::Checkouts;
26
use Koha::DateUtils qw( dt_from_string output_pref );
27
26
28
=head1 NAME
27
=head1 NAME
29
28
(-)a/Koha/REST/V1/Static.pm (-1 / +1 lines)
Lines 19-25 use Modern::Perl; Link Here
19
19
20
use Mojo::Base 'Mojolicious::Controller';
20
use Mojo::Base 'Mojolicious::Controller';
21
21
22
use Try::Tiny;
22
use Try::Tiny qw( catch try );
23
23
24
=head1 API
24
=head1 API
25
25
(-)a/Koha/REST/V1/TransferLimits.pm (-1 / +1 lines)
Lines 25-31 use Koha::Exceptions::TransferLimit; Link Here
25
25
26
use Scalar::Util qw( blessed );
26
use Scalar::Util qw( blessed );
27
27
28
use Try::Tiny;
28
use Try::Tiny qw( catch try );
29
29
30
=head1 NAME
30
=head1 NAME
31
31
(-)a/Koha/Rating.pm (-1 lines)
Lines 17-23 package Koha::Rating; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Ratings.pm (-1 lines)
Lines 17-23 package Koha::Ratings; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/RecordProcessor.pm (-1 / +1 lines)
Lines 59-65 clone it I<prior> to passing it off to the RecordProcessor. Link Here
59
59
60
use Modern::Perl;
60
use Modern::Perl;
61
61
62
use Module::Load::Conditional qw(can_load);
62
use Module::Load::Conditional qw( can_load );
63
use Module::Pluggable::Object;
63
use Module::Pluggable::Object;
64
64
65
use base qw(Class::Accessor);
65
use base qw(Class::Accessor);
(-)a/Koha/Report.pm (-2 lines)
Lines 17-26 package Koha::Report; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use JSON;
24
use Koha::Reports;
22
use Koha::Reports;
25
use Koha::DateUtils qw( dt_from_string output_pref );
23
use Koha::DateUtils qw( dt_from_string output_pref );
26
24
(-)a/Koha/Reports.pm (-1 lines)
Lines 17-23 package Koha::Reports; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Review.pm (-1 lines)
Lines 17-23 package Koha::Review; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Reviews.pm (-1 lines)
Lines 17-23 package Koha::Reviews; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/SMS/Provider.pm (-1 lines)
Lines 19-25 package Koha::SMS::Provider; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Patrons;
23
use Koha::Patrons;
25
24
(-)a/Koha/SMS/Providers.pm (-1 lines)
Lines 19-25 package Koha::SMS::Providers; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::SMS::Provider;
23
use Koha::SMS::Provider;
25
24
(-)a/Koha/SMTP/Server.pm (-1 / +1 lines)
Lines 21-27 use Koha::Database; Link Here
21
use Koha::Exceptions::Object;
21
use Koha::Exceptions::Object;
22
use Koha::SMTP::Servers;
22
use Koha::SMTP::Servers;
23
23
24
use Email::Sender::Transport::SMTP;
24
use Email::Sender::Transport::SMTP ();
25
25
26
use base qw(Koha::Object);
26
use base qw(Koha::Object);
27
27
(-)a/Koha/Schema/Loader/mysql.pm (-1 / +1 lines)
Lines 24-30 use Modern::Perl; Link Here
24
use base 'DBIx::Class::Schema::Loader::DBI::mysql';
24
use base 'DBIx::Class::Schema::Loader::DBI::mysql';
25
use mro 'c3';
25
use mro 'c3';
26
26
27
use Scalar::Util 'blessed';
27
use Scalar::Util qw( blessed );
28
28
29
# This is being upstreamed, but for now lets make sure whatever version of DBIx::Class::Schema::Loader you are using,
29
# This is being upstreamed, but for now lets make sure whatever version of DBIx::Class::Schema::Loader you are using,
30
# we will catch MariaDB current_timestamp() and convert it to \"current_timestamp" correctly.
30
# we will catch MariaDB current_timestamp() and convert it to \"current_timestamp" correctly.
(-)a/Koha/Script.pm (-1 / +1 lines)
Lines 35-41 This class should be used in all scripts. It sets the interface and userenv appr Link Here
35
35
36
=cut
36
=cut
37
37
38
use File::Basename;
38
use File::Basename qw( fileparse );
39
use Fcntl qw(:flock);
39
use Fcntl qw(:flock);
40
40
41
use C4::Context;
41
use C4::Context;
(-)a/Koha/SearchEngine.pm (-1 / +1 lines)
Lines 19-25 package Koha::SearchEngine; Link Here
19
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
# along with Koha; if not, see <http://www.gnu.org/licenses>.
20
20
21
use Modern::Perl;
21
use Modern::Perl;
22
use Readonly;
22
use Readonly qw( Readonly );
23
23
24
=head1 NAME
24
=head1 NAME
25
25
(-)a/Koha/SearchEngine/Elasticsearch.pm (-11 / +10 lines)
Lines 30-50 use Koha::Caches; Link Here
30
use C4::Heading;
30
use C4::Heading;
31
use C4::AuthoritiesMarc;
31
use C4::AuthoritiesMarc;
32
32
33
use Carp;
33
use Carp qw( carp croak );
34
use Clone qw(clone);
34
use Clone qw( clone );
35
use JSON;
36
use Modern::Perl;
35
use Modern::Perl;
37
use Readonly;
36
use Readonly qw( Readonly );
38
use Search::Elasticsearch;
37
use Search::Elasticsearch;
39
use Try::Tiny;
38
use Try::Tiny qw( catch try );
40
use YAML::XS;
39
use YAML::XS ();
41
40
42
use List::Util qw( sum0 reduce all );
41
use List::Util qw( sum0 );
43
use MARC::File::XML;
42
use MARC::File::XML;
44
use MIME::Base64;
43
use MIME::Base64 qw( encode_base64 );
45
use Encode qw(encode);
44
use Encode qw( encode );
46
use Business::ISBN;
45
use Business::ISBN ();
47
use Scalar::Util qw(looks_like_number);
46
use Scalar::Util qw( looks_like_number );
48
47
49
__PACKAGE__->mk_ro_accessors(qw( index index_name ));
48
__PACKAGE__->mk_ro_accessors(qw( index index_name ));
50
__PACKAGE__->mk_accessors(qw( sort_fields ));
49
__PACKAGE__->mk_accessors(qw( sort_fields ));
(-)a/Koha/SearchEngine/Elasticsearch/Indexer.pm (-5 / +4 lines)
Lines 17-34 package Koha::SearchEngine::Elasticsearch::Indexer; Link Here
17
# You should have received a copy of the GNU General Public License
17
# You should have received a copy of the GNU General Public License
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Carp;
20
use Carp qw( carp croak );
21
use Modern::Perl;
21
use Modern::Perl;
22
use Try::Tiny;
22
use Try::Tiny qw( catch try );
23
use List::Util qw(any);
23
use List::Util qw( any );
24
use base qw(Koha::SearchEngine::Elasticsearch);
24
use base qw(Koha::SearchEngine::Elasticsearch);
25
use Data::Dumper;
26
25
27
use Koha::Exceptions;
26
use Koha::Exceptions;
28
use Koha::Exceptions::Elasticsearch;
27
use Koha::Exceptions::Elasticsearch;
29
use Koha::SearchEngine::Zebra::Indexer;
28
use Koha::SearchEngine::Zebra::Indexer;
30
use C4::AuthoritiesMarc qw//;
29
use C4::AuthoritiesMarc qw//;
31
use C4::Biblio;
30
use C4::Biblio ();
32
use C4::Context;
31
use C4::Context;
33
32
34
=head1 NAME
33
=head1 NAME
(-)a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm (-4 / +3 lines)
Lines 40-50 provides something that can be given to elasticsearch to get answers. Link Here
40
=cut
40
=cut
41
41
42
use base qw(Koha::SearchEngine::Elasticsearch);
42
use base qw(Koha::SearchEngine::Elasticsearch);
43
use Carp;
43
use JSON ();
44
use JSON;
44
use List::MoreUtils qw( each_array );
45
use List::MoreUtils qw/ each_array /;
46
use Modern::Perl;
45
use Modern::Perl;
47
use URI::Escape;
46
use URI::Escape qw( uri_escape_utf8 );
48
47
49
use C4::Context;
48
use C4::Context;
50
use Koha::Exceptions;
49
use Koha::Exceptions;
(-)a/Koha/SearchEngine/Elasticsearch/Search.pm (-4 / +2 lines)
Lines 48-58 use Koha::AuthorisedValues; Link Here
48
use Koha::SearchEngine::QueryBuilder;
48
use Koha::SearchEngine::QueryBuilder;
49
use Koha::SearchEngine::Search;
49
use Koha::SearchEngine::Search;
50
use Koha::Exceptions::Elasticsearch;
50
use Koha::Exceptions::Elasticsearch;
51
use MARC::Record;
51
use MARC::Record ();
52
use MARC::File::XML;
52
use MARC::File::XML;
53
use Data::Dumper; #TODO remove
53
use MIME::Base64 qw( decode_base64 );
54
use Carp qw(cluck);
55
use MIME::Base64;
56
54
57
Koha::SearchEngine::Elasticsearch::Search->mk_accessors(qw( store ));
55
Koha::SearchEngine::Elasticsearch::Search->mk_accessors(qw( store ));
58
56
(-)a/Koha/SearchEngine/Indexer.pm (-1 lines)
Lines 45-51 Creates a new C<Search> of whatever the relevant type is. Link Here
45
45
46
use Modern::Perl;
46
use Modern::Perl;
47
use C4::Context;
47
use C4::Context;
48
use C4::Biblio qw//;
49
48
50
sub new {
49
sub new {
51
    my $engine = C4::Context->preference("SearchEngine") // 'Zebra';
50
    my $engine = C4::Context->preference("SearchEngine") // 'Zebra';
(-)a/Koha/SearchEngine/QueryBuilder.pm (-1 / +1 lines)
Lines 45-51 Creates a new C<QueryBuilder> of whatever the relevant type is. Link Here
45
45
46
use C4::Context;
46
use C4::Context;
47
use Modern::Perl;
47
use Modern::Perl;
48
use Carp;
48
use Carp qw( croak );
49
49
50
sub new {
50
sub new {
51
    my $engine = C4::Context->preference("SearchEngine");
51
    my $engine = C4::Context->preference("SearchEngine");
(-)a/Koha/SearchEngine/Search.pm (-2 / +2 lines)
Lines 45-52 Creates a new C<Search> of whatever the relevant type is. Link Here
45
45
46
use Modern::Perl;
46
use Modern::Perl;
47
use C4::Context;
47
use C4::Context;
48
use C4::Biblio qw( GetMarcFromKohaField );
48
use C4::Biblio ();
49
use POSIX qw(ceil floor);
49
use POSIX qw( ceil );
50
50
51
sub new {
51
sub new {
52
    my $engine = C4::Context->preference("SearchEngine") // 'Zebra';
52
    my $engine = C4::Context->preference("SearchEngine") // 'Zebra';
(-)a/Koha/SearchEngine/Zebra/Indexer.pm (-1 / +1 lines)
Lines 18-24 package Koha::SearchEngine::Zebra::Indexer; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use C4::Biblio qw(ModZebra); # FIXME This is terrible, we should move the indexation code outside of C4::Biblio
21
use C4::Biblio qw( ModZebra ); # FIXME This is terrible, we should move the indexation code outside of C4::Biblio
22
use base qw(Class::Accessor);
22
use base qw(Class::Accessor);
23
23
24
=head1 NAME
24
=head1 NAME
(-)a/Koha/SearchField.pm (-1 lines)
Lines 17-23 package Koha::SearchField; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/SearchFields.pm (-1 lines)
Lines 17-23 package Koha::SearchFields; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/SearchMarcMap.pm (-1 lines)
Lines 17-23 package Koha::SearchMarcMap; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/SearchMarcMaps.pm (-1 lines)
Lines 17-23 package Koha::SearchMarcMaps; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Serial.pm (-1 lines)
Lines 19-25 package Koha::Serial; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Serial/Item.pm (-1 lines)
Lines 19-25 package Koha::Serial::Item; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Serial/Items.pm (-1 lines)
Lines 19-25 package Koha::Serial::Items; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Serials.pm (-1 lines)
Lines 19-25 package Koha::Serials; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/SharedContent.pm (-2 / +2 lines)
Lines 18-26 package Koha::SharedContent; Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use JSON;
21
use JSON qw( from_json to_json );
22
use HTTP::Request;
22
use HTTP::Request;
23
use LWP::UserAgent;
23
use LWP::UserAgent ();
24
24
25
use Koha::Serials;
25
use Koha::Serials;
26
use Koha::Reports;
26
use Koha::Reports;
(-)a/Koha/Sitemapper.pm (-1 / +1 lines)
Lines 20-26 package Koha::Sitemapper; Link Here
20
20
21
use Moo;
21
use Moo;
22
use Modern::Perl;
22
use Modern::Perl;
23
use Koha::Sitemapper::Writer;
23
use Koha::Sitemapper::Writer ();
24
use C4::Context;
24
use C4::Context;
25
25
26
26
(-)a/Koha/Sitemapper/Writer.pm (-2 / +2 lines)
Lines 22-29 package Koha::Sitemapper::Writer; Link Here
22
use Moo;
22
use Moo;
23
use Modern::Perl;
23
use Modern::Perl;
24
use XML::Writer;
24
use XML::Writer;
25
use IO::File;
25
use IO::File ();
26
use Koha::DateUtils;
26
use Koha::DateUtils qw( dt_from_string );
27
27
28
28
29
my $MAX = 50000;
29
my $MAX = 50000;
(-)a/Koha/Statistic.pm (-1 lines)
Lines 17-23 package Koha::Statistic; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
use Koha::Items;
22
use Koha::Items;
(-)a/Koha/Statistics.pm (-1 lines)
Lines 17-23 package Koha::Statistics; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/StockRotationItem.pm (-2 / +2 lines)
Lines 22-32 use Modern::Perl; Link Here
22
use DateTime;
22
use DateTime;
23
use DateTime::Duration;
23
use DateTime::Duration;
24
use Koha::Database;
24
use Koha::Database;
25
use Koha::DateUtils qw/dt_from_string/;
25
use Koha::DateUtils qw( dt_from_string );
26
use Koha::Item::Transfer;
26
use Koha::Item::Transfer;
27
use Koha::Item;
27
use Koha::Item;
28
use Koha::StockRotationStage;
28
use Koha::StockRotationStage;
29
use Try::Tiny;
29
use Try::Tiny qw( catch try );
30
30
31
use base qw(Koha::Object);
31
use base qw(Koha::Object);
32
32
(-)a/Koha/Subscription.pm (-2 lines)
Lines 19-25 package Koha::Subscription; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::Biblios;
24
use Koha::Biblios;
Lines 28-34 use Koha::Biblioitems; Link Here
28
use Koha::Subscriptions;
27
use Koha::Subscriptions;
29
use Koha::Subscription::Frequencies;
28
use Koha::Subscription::Frequencies;
30
use Koha::Subscription::Numberpatterns;
29
use Koha::Subscription::Numberpatterns;
31
use JSON;
32
30
33
use base qw(Koha::Object Koha::Object::Mixin::AdditionalFields);
31
use base qw(Koha::Object Koha::Object::Mixin::AdditionalFields);
34
32
(-)a/Koha/Subscription/Frequencies.pm (-1 lines)
Lines 17-23 package Koha::Subscription::Frequencies; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Subscription/Frequency.pm (-1 lines)
Lines 17-23 package Koha::Subscription::Frequency; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Database;
21
use Koha::Database;
23
22
(-)a/Koha/Subscription/Histories.pm (-1 lines)
Lines 19-25 package Koha::Subscription::Histories; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Subscription/History.pm (-1 lines)
Lines 19-25 package Koha::Subscription::History; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Subscription/Routinglist.pm (-1 lines)
Lines 18-24 package Koha::Subscription::Routinglist; Link Here
18
18
19
use Modern::Perl;
19
use Modern::Perl;
20
20
21
use Carp;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
use Koha::Subscriptions;
23
use Koha::Subscriptions;
(-)a/Koha/Subscription/Routinglists.pm (-1 lines)
Lines 18-24 package Koha::Subscription::Routinglists; Link Here
18
18
19
use Modern::Perl;
19
use Modern::Perl;
20
20
21
use Carp;
22
21
23
use Koha::Database;
22
use Koha::Database;
24
use Koha::Subscription::Routinglist;
23
use Koha::Subscription::Routinglist;
(-)a/Koha/Subscriptions.pm (-1 lines)
Lines 19-25 package Koha::Subscriptions; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Suggestion.pm (-2 / +1 lines)
Lines 19-28 package Koha::Suggestion; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
use Koha::DateUtils qw(dt_from_string);
24
use Koha::DateUtils qw( dt_from_string );
26
use Koha::Patrons;
25
use Koha::Patrons;
27
26
28
use base qw(Koha::Object);
27
use base qw(Koha::Object);
(-)a/Koha/SuggestionEngine.pm (-1 / +1 lines)
Lines 53-59 B<new ()> - create a new plugin object Link Here
53
53
54
use strict;
54
use strict;
55
use warnings;
55
use warnings;
56
use Module::Load::Conditional qw(can_load);
56
use Module::Load::Conditional qw( can_load );
57
use Module::Pluggable::Object;
57
use Module::Pluggable::Object;
58
58
59
use base qw(Class::Accessor);
59
use base qw(Class::Accessor);
(-)a/Koha/SuggestionEngine/Plugin/AuthorityFile.pm (-1 lines)
Lines 31-37 Plugin to get suggestions from Koha's authority file Link Here
31
=cut
31
=cut
32
32
33
use Modern::Perl;
33
use Modern::Perl;
34
use Carp;
35
34
36
use base qw(Koha::SuggestionEngine::Base);
35
use base qw(Koha::SuggestionEngine::Base);
37
36
(-)a/Koha/SuggestionEngine/Plugin/ExplodedTerms.pm (-1 lines)
Lines 32-38 subjects to subject searches. Link Here
32
=cut
32
=cut
33
33
34
use Modern::Perl;
34
use Modern::Perl;
35
use Carp;
36
use C4::Templates qw(gettemplate); # This is necessary for translatability
35
use C4::Templates qw(gettemplate); # This is necessary for translatability
37
36
38
use base qw(Koha::SuggestionEngine::Base);
37
use base qw(Koha::SuggestionEngine::Base);
(-)a/Koha/SuggestionEngine/Plugin/LibrisSpellcheck.pm (-2 / +2 lines)
Lines 17-24 package Koha::SuggestionEngine::Plugin::LibrisSpellcheck; Link Here
17
# along with Koha; if not, see <http://www.gnu.org/licenses>.
17
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
18
19
use Modern::Perl;
19
use Modern::Perl;
20
use LWP::UserAgent;
20
use LWP::UserAgent ();
21
use XML::Simple qw(XMLin);
21
use XML::Simple qw( XMLin );
22
use C4::Context;
22
use C4::Context;
23
use base qw(Koha::SuggestionEngine::Base);
23
use base qw(Koha::SuggestionEngine::Base);
24
24
(-)a/Koha/SuggestionEngine/Plugin/Null.pm (-1 lines)
Lines 33-39 SuggestionEngine. Link Here
33
33
34
use strict;
34
use strict;
35
use warnings;
35
use warnings;
36
use Carp;
37
36
38
use base qw(Koha::SuggestionEngine::Base);
37
use base qw(Koha::SuggestionEngine::Base);
39
38
(-)a/Koha/Suggestions.pm (-1 lines)
Lines 19-25 package Koha::Suggestions; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Carp;
23
22
24
use Koha::Database;
23
use Koha::Database;
25
24
(-)a/Koha/Tag.pm (-1 lines)
Lines 17-23 package Koha::Tag; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Tags.pm (-1 lines)
Lines 17-23 package Koha::Tags; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Tag;
21
use Koha::Tag;
23
22
(-)a/Koha/Tags/Approval.pm (-1 lines)
Lines 17-23 package Koha::Tags::Approval; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Tags/Approvals.pm (-1 lines)
Lines 17-23 package Koha::Tags::Approvals; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Tags::Approval;
21
use Koha::Tags::Approval;
23
22
(-)a/Koha/Tags/Index.pm (-1 lines)
Lines 17-23 package Koha::Tags::Index; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use base qw(Koha::Object);
21
use base qw(Koha::Object);
23
22
(-)a/Koha/Tags/Indexes.pm (-1 lines)
Lines 17-23 package Koha::Tags::Indexes; Link Here
17
17
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use Carp;
21
20
22
use Koha::Tags::Index;
21
use Koha::Tags::Index;
23
22
(-)a/Koha/Template/Plugin/Asset.pm (-2 / +2 lines)
Lines 45-52 use Modern::Perl; Link Here
45
use Template::Plugin;
45
use Template::Plugin;
46
use base qw( Template::Plugin );
46
use base qw( Template::Plugin );
47
47
48
use File::Basename;
48
use File::Basename qw( fileparse );
49
use File::Spec;
49
use File::Spec ();
50
use C4::Context;
50
use C4::Context;
51
use Koha;
51
use Koha;
52
52
(-)a/Koha/Template/Plugin/AudioAlerts.pm (-2 / +1 lines)
Lines 19-26 package Koha::Template::Plugin::AudioAlerts; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
21
22
use Encode qw( encode );
22
use JSON qw( encode_json );
23
use JSON;
24
23
25
use base qw( Template::Plugin );
24
use base qw( Template::Plugin );
26
25
(-)a/Koha/Template/Plugin/Categories.pm (-1 / +1 lines)
Lines 20-26 use Modern::Perl; Link Here
20
use Template::Plugin;
20
use Template::Plugin;
21
use base qw( Template::Plugin );
21
use base qw( Template::Plugin );
22
22
23
use List::Util qw(any);
23
use List::Util qw( any );
24
use Koha::Patron::Categories;
24
use Koha::Patron::Categories;
25
25
26
sub all {
26
sub all {
(-)a/Koha/Template/Plugin/I18N.pm (-1 / +1 lines)
Lines 22-28 use Modern::Perl; Link Here
22
use base qw( Template::Plugin );
22
use base qw( Template::Plugin );
23
23
24
use C4::Context;
24
use C4::Context;
25
use Koha::I18N;
25
use Koha::I18N qw( __ __n __np __npx __nx __p __px __x __xn );
26
26
27
=head1 NAME
27
=head1 NAME
28
28
(-)a/Koha/Template/Plugin/KohaDates.pm (-1 / +1 lines)
Lines 22-28 use Modern::Perl; Link Here
22
use Template::Plugin::Filter;
22
use Template::Plugin::Filter;
23
use base qw( Template::Plugin::Filter );
23
use base qw( Template::Plugin::Filter );
24
24
25
use Koha::DateUtils;
25
use Koha::DateUtils qw( dt_from_string output_pref );
26
use C4::Context;
26
use C4::Context;
27
our $DYNAMIC = 1;
27
our $DYNAMIC = 1;
28
28
(-)a/Koha/Template/Plugin/KohaNews.pm (-1 / +1 lines)
Lines 26-32 use base qw( Template::Plugin ); Link Here
26
26
27
use C4::Koha;
27
use C4::Koha;
28
use C4::Context;
28
use C4::Context;
29
use C4::NewsChannels; # GetNewsToDisplay
29
use C4::NewsChannels qw( GetNewsToDisplay ); # GetNewsToDisplay
30
30
31
sub get {
31
sub get {
32
    my ( $self, $params ) = @_;
32
    my ( $self, $params ) = @_;
(-)a/Koha/Template/Plugin/KohaPlugins.pm (-1 / +1 lines)
Lines 21-27 use Modern::Perl; Link Here
21
21
22
use base qw( Template::Plugin );
22
use base qw( Template::Plugin );
23
23
24
use Try::Tiny;
24
use Try::Tiny qw( catch try );
25
25
26
use Koha::Plugins;
26
use Koha::Plugins;
27
27
(-)a/Koha/Template/Plugin/Languages.pm (-1 / +1 lines)