Bugzilla – Attachment 38592 Details for
Bug 14066
Koha code does not really use Readonly
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[Signed-off] Bug 14066: Remove the Readonly[::XS] dependency
Signed-off-Bug-14066-Remove-the-ReadonlyXS-depende.patch (text/plain), 2.41 KB, created by
Marc Véron
on 2015-04-28 04:59:57 UTC
(
hide
)
Description:
[Signed-off] Bug 14066: Remove the Readonly[::XS] dependency
Filename:
MIME Type:
Creator:
Marc Véron
Created:
2015-04-28 04:59:57 UTC
Size:
2.41 KB
patch
obsolete
>From 3a9aa0d39ae20411624214c6104cb65012862b9a Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Mon, 27 Apr 2015 13:42:20 +0200 >Subject: [PATCH] [Signed-off] Bug 14066: Remove the Readonly[::XS] dependency >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >The Readonly and Readonly::XS package are only used in Koha::Calendar. >IMO the added value of there packages does not justify their purpose. > >Test plan: >1/ Remove Readonly and Readonly::XS >2/ Open the calendar and confirm you don't get any error concerning missing >dependency > >Signed-off-by: Mark Tompsett <mtompset@hotmail.com> >Signed-off-by: Marc Véron <veron@veron.ch> >--- > C4/Installer/PerlDependencies.pm | 10 ---------- > Koha/Calendar.pm | 5 ++--- > 2 files changed, 2 insertions(+), 13 deletions(-) > >diff --git a/C4/Installer/PerlDependencies.pm b/C4/Installer/PerlDependencies.pm >index 67ec808..ac59c30 100644 >--- a/C4/Installer/PerlDependencies.pm >+++ b/C4/Installer/PerlDependencies.pm >@@ -237,16 +237,6 @@ our $PERL_DEPS = { > 'required' => '1', > 'min_ver' => '0.08' > }, >- 'Readonly' => { >- 'usage' => 'Core', >- 'required' => '1', >- 'min_ver' => '1.03' >- }, >- 'Readonly::XS' => { >- 'usage' => 'Core', >- 'required' => '0', >- 'min_ver' => '1.02' >- }, > 'Graphics::Magick' => { > 'usage' => 'Patron Card Creator Feature', > 'required' => '0', >diff --git a/Koha/Calendar.pm b/Koha/Calendar.pm >index 6013a25..451c6a3 100644 >--- a/Koha/Calendar.pm >+++ b/Koha/Calendar.pm >@@ -8,7 +8,6 @@ use DateTime::Set; > use DateTime::Duration; > use C4::Context; > use Carp; >-use Readonly; > > sub new { > my ( $classname, %options ) = @_; >@@ -34,7 +33,7 @@ sub _init { > ); > $weekly_closed_days_sth->execute( $branch ); > $self->{weekly_closed_days} = [ 0, 0, 0, 0, 0, 0, 0 ]; >- Readonly::Scalar my $sunday => 7; >+ my $sunday => 7; > while ( my $tuple = $weekly_closed_days_sth->fetchrow_hashref ) { > $self->{weekly_closed_days}->[ $tuple->{weekday} ] = 1; > } >@@ -127,7 +126,7 @@ sub addDate { > > if ( $unit eq 'hours' ) { > # Fixed for legacy support. Should be set as a branch parameter >- Readonly::Scalar my $return_by_hour => 10; >+ my $return_by_hour => 10; > > $dt = $self->addHours($startdate, $add_duration, $return_by_hour); > } else { >-- >1.7.10.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 14066
:
38546
|
38577
|
38578
|
38579
|
38580
|
38591
|
38592
|
38593
|
38787
|
38788
|
38789