From: phasefx Date: Sun, 21 Sep 2008 02:12:04 +0000 (+0000) Subject: Make this method return 1 and 0 like the description says. Currently the staff clien... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=828c44cebd7a0a119183bcdb856c235bca90ceba;p=Evergreen.git Make this method return 1 and 0 like the description says. Currently the staff client can't distinguish legitimate null returns from network errors git-svn-id: svn://svn.open-ils.org/ILS/trunk@10660 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Actor.pm b/Open-ILS/src/perlmods/OpenILS/Application/Actor.pm index 5e17c0fd90..7a7c2191d5 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Actor.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Actor.pm @@ -2602,8 +2602,13 @@ sub barcode_exists { my $e = new_editor(authtoken=>$auth); return $e->event unless $e->checkauth; my $card = $e->search_actor_card({barcode => $barcode}); - return undef unless @$card; - return $card->[0]->usr; + if (@$card) { + return 1; + } else { + return 0; + } + #return undef unless @$card; + #return $card->[0]->usr; }