From: pines Date: Mon, 12 Feb 2007 18:57:25 +0000 (+0000) Subject: making sure the active card is linked from the "card" field on the user in the fleshe... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=5f1ff2a01e22caa66299be53e2e1766e365424a1;p=Evergreen.git making sure the active card is linked from the "card" field on the user in the fleshed retrieval method git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_1_0@6933 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 5043eb75bf..25b610ab4c 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Actor.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Actor.pm @@ -2698,6 +2698,11 @@ sub new_flesh_user { } } + $user->card( (grep { $U->is_true($_->active) } @{$user->cards})[0] ) + if grep { /card$/ } @$fields and + grep { /cards/ } @$fields and + not $U->is_true($user->card->active); + $e->rollback; $user->clear_passwd(); return $user;