]> git.koha-community.org Git - koha.git/commit
Bug 11779: (follow-up) improve GetLoggedInBranchcode() and add test cases
authorGalen Charlton <gmc@esilibrary.com>
Wed, 19 Feb 2014 16:40:06 +0000 (16:40 +0000)
committerGalen Charlton <gmc@esilibrary.com>
Wed, 19 Feb 2014 16:40:06 +0000 (16:40 +0000)
commit065a3a5efa9b90723460a607ac85591c17945b00
tree27fff17d62dcfc2129b0378d499f8fc395fe9b92
parent858083c8e907bde4efa6842cd45ff91bf1f6e24f
Bug 11779: (follow-up) improve GetLoggedInBranchcode() and add test cases

This patch adjusts the new GetLoggedInBranchcode() template function so
that it returns the empty string rather than undef if there is no
active user environment.  That way, there won't be lots of undefined
value warnings if/when this function gets used in the OPAC.

This patch also adds test cases.

To test:

[1] Verify that there are no regressions in the main test
    plan for this bug.
[2] Verify that prove -v t/db_dependent/Koha_template_plugin_Branches.t
    passes.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Koha/Template/Plugin/Branches.pm
t/db_dependent/Koha_template_plugin_Branches.t