From 6ba2f7bff4bb368373ad615efc70a50aedd5df17 Mon Sep 17 00:00:00 2001 From: dbwells Date: Fri, 4 Mar 2011 19:46:13 +0000 Subject: [PATCH] Respect a setting of depth=0. In particular, this fixes holdings requests for branch-level searches with an 'Everything' scope. git-svn-id: svn://svn.open-ils.org/ILS/trunk@19583 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm index 9f4f183ce..107fc35c2 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm @@ -536,7 +536,7 @@ sub unapi { $lib_id = $lib_object->id; $ou_types = $actor->request( 'open-ils.actor.org_types.retrieve' )->gather(1); - $lib_depth = $depth || (grep { $_->id == $lib_object->ou_type } @$ou_types)[0]->depth; + $lib_depth = defined($depth) ? $depth : (grep { $_->id == $lib_object->ou_type } @$ou_types)[0]->depth; } if ($command eq 'browse') { -- 2.11.0