[open-ils-commits] r11368 - trunk/Open-ILS/src/perlmods/OpenILS/Application/Circ
svn at svn.open-ils.org
svn at svn.open-ils.org
Mon Dec 1 13:58:28 EST 2008
Author: erickson
Date: 2008-12-01 13:58:25 -0500 (Mon, 01 Dec 2008)
New Revision: 11368
Modified:
trunk/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm
Log:
don't bother loading the static circ scripts if legacy circ support is disabled
Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm 2008-11-30 04:36:14 UTC (rev 11367)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm 2008-12-01 18:58:25 UTC (rev 11368)
@@ -17,19 +17,24 @@
my $self = shift;
my $conf = OpenSRF::Utils::SettingsClient->new;
my @pfx2 = ( "apps", "open-ils.circ","app_settings" );
- my @pfx = ( @pfx2, "scripts" );
- my $p = $conf->config_value( @pfx, 'circ_permit_patron' );
- my $c = $conf->config_value( @pfx, 'circ_permit_copy' );
- my $d = $conf->config_value( @pfx, 'circ_duration' );
- my $f = $conf->config_value( @pfx, 'circ_recurring_fines' );
- my $m = $conf->config_value( @pfx, 'circ_max_fines' );
- my $pr = $conf->config_value( @pfx, 'circ_permit_renew' );
- my $lb = $conf->config_value( @pfx2, 'script_path' );
-
$legacy_script_support = $conf->config_value(@pfx2, 'legacy_script_support');
$legacy_script_support = ($legacy_script_support and $legacy_script_support =~ /true/i);
+ my $lb = $conf->config_value( @pfx2, 'script_path' );
+ $lb = [ $lb ] unless ref($lb);
+ $script_libs = $lb;
+
+ return unless $legacy_script_support;
+
+ my @pfx = ( @pfx2, "scripts" );
+ my $p = $conf->config_value( @pfx, 'circ_permit_patron' );
+ my $c = $conf->config_value( @pfx, 'circ_permit_copy' );
+ my $d = $conf->config_value( @pfx, 'circ_duration' );
+ my $f = $conf->config_value( @pfx, 'circ_recurring_fines' );
+ my $m = $conf->config_value( @pfx, 'circ_max_fines' );
+ my $pr = $conf->config_value( @pfx, 'circ_permit_renew' );
+
$logger->error( "Missing circ script(s)" )
unless( $p and $c and $d and $f and $m and $pr );
@@ -40,9 +45,6 @@
$scripts{circ_max_fines} = $m;
$scripts{circ_permit_renew} = $pr;
- $lb = [ $lb ] unless ref($lb);
- $script_libs = $lb;
-
$logger->debug(
"circulator: Loaded rules scripts for circ: " .
"circ permit patron = $p, ".
More information about the open-ils-commits
mailing list