https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22823 Bug ID: 22823 Summary: Koha::Library needs a method for obtaining the incoming email address Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: martin.renvoize@ptfs-europe.com QA Contact: testopia@bugs.koha-community.org Target Milestone: --- There's a code pattern emerging (in bug 5770 and bug 22821 at least to my knowledge) where we grab a branches email address to send notifications to the branch. However, it's prone to make mistakes in the fallback order for assigning that address so we should factor it out into a method that can be called from Koha::Library. Should be as simple as
sub to_email { my $self = shift; return $self->branchreplyto || $self->branchemail || C4::Context->preference('ReplytoDefault') || C4::Context->preference('KohaAdminEmailAddress'); }
along with some appropriate POD and a walk of the codebase to replace existing occurrences of the pattern. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.