From df763b1a541636d5f61aee51ce325e0a9869c0ca Mon Sep 17 00:00:00 2001 From: erickson Date: Thu, 16 Oct 2008 19:04:09 +0000 Subject: [PATCH] if no max is configured and no valid count from the SC, default to 4, which was the previous default git-svn-id: svn://svn.open-ils.org/ILS/trunk@10851 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/OpenILS/Application/Circ.pm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm b/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm index 6881081ad5..3fe64b46e0 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm @@ -606,9 +606,11 @@ sub view_circs { my $max_history = $U->ou_ancestor_setting_value( $e->requestor->ws_ou, 'circ.item_checkout_history.max', $e); - $count = $max_history if $max_history and (!$count or $count > $max_history); - - return [] unless $count; + if(defined $max_history) { + $count = $max_history unless defined $count and $count < $max_history; + } else { + $count = 4 unless defined $count; + } return $e->search_action_circulation([ {target_copy => $copyid}, -- 2.11.0