@@ -, +, @@ when editing borrower attributes and messaging preferences preferences. This happens to all/most of the sub-forms in the Borrower's Details-view. errors. --- members/memberentry.pl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) --- a/members/memberentry.pl +++ a/members/memberentry.pl @@ -328,8 +328,10 @@ if ($op eq 'save' || $op eq 'insert'){ } } } - # Check if the userid is unique - unless (Check_Userid($newdata{'userid'},$borrowernumber)) { + # Check if the userid is unique. Userid might not always be present in the edited values list when editing certain sub-forms, so we need to dig for it a bit. + my $userid = $newdata{'userid'}; + $userid = $borrower_data->{userid} unless $userid; #Get the userid straight from the DB + unless (Check_Userid($userid,$borrowernumber)) { push @errors, "ERROR_login_exist"; } --