From: Thomas Berezansky Date: Tue, 5 Jul 2011 21:13:05 +0000 (-0400) Subject: Can't use 0 in true/false, use defined instead X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=afdf624007f38ff4d9f7d575a6270dc557d3e117;p=evergreen%2Fpines.git Can't use 0 in true/false, use defined instead This allows for setting renewals/grace period to 0 by force Signed-off-by: Thomas Berezansky Signed-off-by: Mike Rylander --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Circulate.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Circulate.pm index 2d4270497b..cbdb4fcb4d 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Circulate.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Circulate.pm @@ -1174,11 +1174,11 @@ sub run_indb_circ_test { $logger->info("circulator: circ policy test found matchpoint built via rows " . $results->[0]->{buildrows}); $self->circ_matrix_matchpoint($self->editor->retrieve_config_circ_matrix_matchpoint($mp)); $self->circ_matrix_matchpoint->duration_rule($self->editor->retrieve_config_rules_circ_duration($results->[0]->{duration_rule})); - if($results->[0]->{renewals}) { + if(defined($results->[0]->{renewals})) { $self->circ_matrix_matchpoint->duration_rule->max_renewals($results->[0]->{renewals}); } $self->circ_matrix_matchpoint->recurring_fine_rule($self->editor->retrieve_config_rules_recurring_fine($results->[0]->{recurring_fine_rule})); - if($results->[0]->{grace_period}) { + if(defined($results->[0]->{grace_period})) { $self->circ_matrix_matchpoint->recurring_fine_rule->grace_period($results->[0]->{grace_period}); } $self->circ_matrix_matchpoint->max_fine_rule($self->editor->retrieve_config_rules_max_fine($results->[0]->{max_fine_rule}));