Koha/t/db_dependent/Template/Plugin
Fridolin Somers 666ec45473 Bug 29826: Manage call of Template Plugin Branches GetName() with null or empty branchcode
Bug 26587 added a concatenation that sends a warning if var is undef :
$ prove t/db_dependent/Template/Plugin/Branches.t
Use of uninitialized value $branchcode in concatenation (.) or string at /kohadevbox/koha/Koha/Template/Plugin/Branches.pm line 35.

This patch adds an early return empty string when GetName is called with $branchcode null or empty string.

Test plan :
1) Run t/db_dependent/Template/Plugin/Branches.t without patch
2) Run with the patch to see warning disappear

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
2022-03-03 16:11:50 -10:00
..
AuthorisedValues.t Bug 26384: Fix executable flags 2020-09-11 09:56:56 +02:00
Branches.t Bug 29826: Manage call of Template Plugin Branches GetName() with null or empty branchcode 2022-03-03 16:11:50 -10:00
Categories.t Bug 29844: Some more uncaught cases 2022-02-09 15:36:23 -10:00
CirculationRules.t Bug 24154: (follow-up) Make parameter and variable more explicit, add tests 2021-05-10 10:27:53 +02:00
KohaDates.t Bug 28931: Use EXPORT_OK from Koha::DateUtils 2021-10-07 11:01:05 +02:00
To.t Bug 26384: Fix executable flags 2020-09-11 09:56:56 +02:00