Bugzilla – Attachment 12133 Details for
Bug 7621
Circulation: Match age restriction of title with borrower's age without using categories
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 7621: Followup: FIX warnings "Scalar value @values[$take] better written as $values[$take]"
SIGNED-OFF-Bug-7621-Followup-FIX-warnings-Scalar-v.patch (text/plain), 1.66 KB, created by
Marc Véron
on 2012-09-11 13:59:55 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 7621: Followup: FIX warnings "Scalar value @values[$take] better written as $values[$take]"
Filename:
MIME Type:
Creator:
Marc Véron
Created:
2012-09-11 13:59:55 UTC
Size:
1.66 KB
patch
obsolete
>From 891ef21f7c1658041e189569732872410704ebc1 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Tue, 11 Sep 2012 15:15:17 +0200 >Subject: [PATCH] [SIGNED-OFF] Bug 7621: Followup: FIX warnings "Scalar value @values[$take] better written as $values[$take]" >Content-Type: text/plain; charset="utf-8" > >The previous patch introduces some perl warnings in log > >Signed-off-by: Marc Veron <veron@veron.ch> >Tested with age restriction scenarios I used for development. Still works as expected. >--- > C4/Circulation.pm | 8 ++++---- > 1 files changed, 4 insertions(+), 4 deletions(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index 8bd53b9..273c6f3 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -982,16 +982,16 @@ sub CanBookBeIssued { > # Index points to the next value > my $restrictionyear = 0; > if (($take <= $#values) && ($take >= 0)){ >- $restrictionyear += @values[$take]; >+ $restrictionyear += $values[$take]; > } > > if ($restrictionyear > 0) { > if ( $borrower->{'dateofbirth'} ) { > my @alloweddate = split /-/,$borrower->{'dateofbirth'} ; >- @alloweddate[0] += $restrictionyear; >+ $alloweddate[0] += $restrictionyear; > #Prevent runime eror on leap year (invalid date) >- if ((@alloweddate[1] == 2) && (@alloweddate[2] == 29)) { >- @alloweddate[2] = 28; >+ if (($alloweddate[1] == 2) && ($alloweddate[2] == 29)) { >+ $alloweddate[2] = 28; > } > > if ( Date_to_Days(Today) < Date_to_Days(@alloweddate) -1 ) { >-- >1.7.2.5
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 7621
:
9176
|
9219
|
9979
|
10072
|
10136
|
10141
|
10142
|
10143
|
10144
|
10395
|
10550
|
10650
|
10657
|
10658
|
10859
|
10866
|
10896
|
11130
|
11550
|
11938
|
11939
|
12132
|
12133
|
12547
|
12558
|
12559
|
12563