https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27857 --- Comment #3 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 117711 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=117711&action=edit Bug 27857: Make Koha::Patron->extended_attributes validate data This patch makes the extended_attributes method use Koha::Patron->add_extended_attribute inside the loop, instead of direct DB access. This way, it takes advantage of the validation that is done there. All happens inside a transaction, so if 'add_extended_attribute' throws an exception, everything is rolled back. To test: 1. Apply the previous patches 2. Run: $ kshell k$ prove t/db_dependent/Koha/Patron.t => FAIL: The behavior is not the correct one, tests fail 3. Apply this patch 4. Repeat 2 => SUCCESS: Tests pass! 5. Sign off :-D -- You are receiving this mail because: You are watching all bug changes.