don't consider invalide addrs with negative IDs, since those are replaced addrs
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 30 Jul 2009 13:11:07 +0000 (13:11 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 30 Jul 2009 13:11:07 +0000 (13:11 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@13782 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/perlmods/OpenILS/Application/Actor.pm

index 7d2fb15..d6b5196 100644 (file)
@@ -317,7 +317,8 @@ sub apply_invalid_addr_penalty {
     my $enforce = $U->ou_ancestor_setting_value(
         $patron->home_ou, 'circ.patron_invalid_address_apply_penalty') || 0;
 
-    my $addrs = $e->search_actor_user_address({usr => $patron->id, valid => 'f'}, {idlist => 1});
+    my $addrs = $e->search_actor_user_address(
+        {usr => $patron->id, valid => 'f', id => {'>' => 0}}, {idlist => 1});
     my $addr_count = scalar(@$addrs);
 
     if($addr_count == 0 and $addr_penalty) {