]> git.koha-community.org Git - koha.git/commit
Bug 22823: Add get_effective_email method to Koha::Library
authorMartin Renvoize <martin.renvoize@ptfs-europe.com>
Mon, 24 Feb 2020 20:42:30 +0000 (20:42 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Wed, 18 Mar 2020 15:44:26 +0000 (15:44 +0000)
commit40c08434d4853c888a67d3c5a2cde75b64c13a75
treef7f40b5643bf95aa895c50a7e1039c475cdb25a5
parentb16d43394376bdcfbcaaaf2f5543567c3aec9771
Bug 22823: Add get_effective_email method to Koha::Library

Add a `get_effective_email` method to the Koha::Library object which
returns the email address for the library which they are most likely to
have access to.

This method falls back through preferences `branchreplyto`, `branchemail`,
`ReplytoDefault`, `KohaAdminEmailAddress`.

This bug simply introduces a new utility function to return the most effective email address for a branch to be emailed on.

Test plan
1/ Read the new test and verify it makes sense
2/ Run the tests and verify they all pass.

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Koha/Library.pm