@@ -, +, @@ # Failed test 'Attribute 1 should be retrieved correctly' # at t/db_dependent/Koha/Pseudonymization.t line 198. # Structures begin differing at: # $got->{borrowernumber} = Does not exist # $expected->{borrowernumber} = '58' # Failed test 'Attribute 2 should be retrieved correctly' # at t/db_dependent/Koha/Pseudonymization.t line 204. # Structures begin differing at: # $got->{borrowernumber} = Does not exist # $expected->{borrowernumber} = '58' # Looks like you failed 2 tests of 3. commit 7b40ee22035210e3fbdfe75785d68ca314285409 Bug 27857: Make Koha::Patron->extended_attributes validate data --- Koha/Patron.pm | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) --- a/Koha/Patron.pm +++ a/Koha/Patron.pm @@ -1539,8 +1539,14 @@ sub generate_userid { sub add_extended_attribute { my ($self, $attribute) = @_; - $attribute->{borrowernumber} = $self->borrowernumber; - return Koha::Patron::Attribute->new($attribute)->store; + + return Koha::Patron::Attribute->new( + { + %$attribute, + ( borrowernumber => $self->borrowernumber ), + } + )->store; + } =head3 extended_attributes --