Bug 23077: Don't fill cardnumber with empty string

To test:
1 - Apply unit test patch only
2 - prove the tests, they fail
3 - Attempt to import the attached sample file
4 - First patron may be imported, second will give error (or both will error)
5 - If only one error, import agian, now both have error
6 - Apply this patch
7 - Prove tests, they pass!
8 - Import the sample file
9 - It succeeds!

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit cc60770c4e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 80cac150b8)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
Nick Clemens 2019-06-07 12:19:28 +00:00 committed by Lucas Gass
parent 225c3ba5ed
commit b450462d74
1 changed files with 1 additions and 0 deletions

View File

@ -132,6 +132,7 @@ sub import_patrons {
}
}
}
$borrower{cardnumber} = undef unless $borrower{cardnumber};
# Check if borrower category code exists and if it matches to a known category. Pushing error to missing_criticals otherwise.
$self->check_borrower_category($borrower{categorycode}, $borrowerline, $line_number, \@missing_criticals);