Bugzilla – Attachment 38399 Details for
Bug 14036
"Date::Calc::Add_Delta_YM(): not a valid date" error when accessing subscription detail
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch that adds date validation
bug-14036.patch (text/plain), 939 bytes, created by
Rolando Isidoro
on 2015-04-23 11:00:12 UTC
(
hide
)
Description:
Patch that adds date validation
Filename:
MIME Type:
Creator:
Rolando Isidoro
Created:
2015-04-23 11:00:12 UTC
Size:
939 bytes
patch
obsolete
>diff --git a/C4/Serials.pm b/C4/Serials.pm >index 72dc44b..86ffb15 100644 >--- a/C4/Serials.pm >+++ b/C4/Serials.pm >@@ -2246,6 +2246,9 @@ sub abouttoexpire { > my $expirationdate = GetExpirationDate($subscriptionid); > my ($res) = $dbh->selectrow_array('select max(planneddate) from serial where subscriptionid = ?', undef, $subscriptionid); > my $nextdate = GetNextDate($subscription, $res); >+ >+ return unless ($nextdate and $expirationdate); >+ > if(Date::Calc::Delta_Days( > split( /-/, $nextdate ), > split( /-/, $expirationdate ) >@@ -2383,6 +2386,8 @@ sub GetNextDate { > if ($freqdata->{'unit'}) { > my ( $year, $month, $day ) = split /-/, $publisheddate; > >+ return unless check_date($year, $month, $day); >+ > # Process an irregularity Hash > # Suppose that irregularities are stored in a string with this structure > # irreg1;irreg2;irreg3
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 14036
:
38399
|
38459
|
38461
|
38464
|
38465
|
38466
|
38467
|
38468