---
 tools/import_borrowers.pl |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/tools/import_borrowers.pl b/tools/import_borrowers.pl
index 9738f19..5d477ef 100755
--- a/tools/import_borrowers.pl
+++ b/tools/import_borrowers.pl
@@ -143,6 +143,12 @@ if ( $uploadborrowers && length($uploadborrowers) > 0 ) {
             push @missing_criticals, {badparse=>1, line=>$., 
lineraw=>$borrowerline};
         } elsif (@columns == @columnkeys) {
             @borrow...@columnkeys} = @columns;
+            # MJR: try to fill blanks gracefully by using default values
+            foreach my $key (@criticals) {
+                if ($borrower{$key} !~ /\S/) {
+                    $borrower{$key} = $defaults{$key};
+                }
+            } 
         } else {
             # MJR: try to recover gracefully by using default values
             foreach my $key (@columnkeys) {
-- 
1.5.3.7

_______________________________________________
Koha-patches mailing list
[email protected]
http://lists.koha.org/mailman/listinfo/koha-patches

Reply via email to