]> git.koha-community.org Git - koha.git/commit
Bug 36277: Avoid useless warnings
authorTomas Cohen Arazi <tomascohen@theke.io>
Fri, 15 Mar 2024 12:05:55 +0000 (09:05 -0300)
committerFridolin Somers <fridolin.somers@biblibre.com>
Mon, 18 Mar 2024 09:24:37 +0000 (10:24 +0100)
commitfa2e164f240a9e040c0e044c39dac6c613cb7b27
tree30d5dd1c897f179b2f6b59368ed0a1d761ca7fae
parent372adf555d579c290355ff33f891cd205dc0bfac
Bug 36277: Avoid useless warnings

As mentioned on bug 36329, this endpoint is only used with one of this
parameters:

* item_type
* collection_code

The other will be NULL both on the DB and the (deserialized) request
body. For the data from the DB, the author added `|| q{}` but missed to
do so on the incoming parameters when generates the hash key.

This generates the following warnings when using from the UI:

[2024/03/15 11:42:51] [WARN] Use of uninitialized value in sprintf at /kohadevbox/koha/Koha/REST/V1/TransferLimits.pm line 146.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 03b0f31b9e63ce314c333ac6ffd68587a609e587)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Koha/REST/V1/TransferLimits.pm