https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37757
--- Comment #3 from Tomás Cohen Arazi <[email protected]> --- Created attachment 170842 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=170842&action=edit Bug 37757: Make notice_email_address() handle EmailFieldPrimary values more robustly This patchset makes: * The EmailFieldPrimary value 'OFF' be replaced by an empty string * Koha::Patron->notice_email_address() handle the empty case more gracefully To test: 1. On main, manually set the EmailFieldPrimary syspref to empty $ ktd --shell k$ koha-mysql kohadev > UPDATE systempreferences SET value='' WHERE variable='EmailFieldPrimary'; 2. Enable `AutoEmailNewUser` 3. Create a new user => FAIL: Koha explodes like: ``` The method Koha::Patron-> is not covered by tests! Trace begun at /kohadevbox/koha/Koha/Object.pm line 992 Koha::Object::AUTOLOAD('Koha::Patron=HASH(0xaaaae37ac550)') called at /kohadevbox/koha/Koha/Patron.pm line 1662 Koha::Patron::notice_email_address('Koha::Patron=HASH(0xaaaae37ac550)') called at /kohadevbox/koha/members/memberentry.pl line 448 ... 4. Apply this patches 5. Run: k$ updatedatabase => SUCCESS: Update succeeds 6. Restart all and retry creating a patron => SUCCESS: It worked! 7. Sign off :-D -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
