Koha-clms/Koha/Util
Janusz Kaczmarek fb2e54b0c3
Bug 36976: Warning 'Argument "" isn't numeric in numeric' in log when merging bibliographic records
When merging bibliographic records, Koha generates warning:

[WARN] Argument "" isn't numeric in numeric ge (>=) at /kohadevbox/koha/Koha/Util/MARC.pm line 81.

in [plack-]intranet-error.log.

This is because $tagslib->{$fieldtag}->{'tab'} -- for a tag, not for a
subfield --is (always?) an empty string (cf.
C4::Biblio::GetMarcStructure : $res->{$tag}->{tab} = ""), and in
Koha::Util::MARC::createMergeHash it is compared numerically with 0.

Test plan:
==========
1. From biblio search result page, selact two records with the checkboxes
   and start a merge (Edit -> Merge records).  Proceed with merging.
   After the merge, controll the content of the plack-intranet-error.log
   (when using plack -- standard in ktd).  Note the lines:
   [WARN] Argument "" isn't numeric in numeric ge (>=) at /kohadevbox/koha/Koha/Util/MARC.pm line 81.
2. Apply the patch; restart_all.
3. Repeat p. 1.  There should be no fresh warnings.

Sponsored-by: Ignatianum University in Cracow
Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-06-28 13:49:24 +02:00
..
FrameworkPlugin.pm Bug 27461: Move hardcoded value to module 2021-09-28 15:12:45 +02:00
MARC.pm Bug 36976: Warning 'Argument "" isn't numeric in numeric' in log when merging bibliographic records 2024-06-28 13:49:24 +02:00
Navigation.pm Bug 26127: local_referer should not compare with OPACBaseURL case insensitive 2020-08-18 14:47:44 +02:00
Normalize.pm Bug 24545: Fix license statements 2020-02-24 13:31:26 +00:00
OpenDocument.pm Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
StockRotation.pm Bug 22569: Add a 'Transfers to send' report 2021-03-11 11:51:40 +01:00