diff --git a/Koha/Patron/Modification.pm b/Koha/Patron/Modification.pm index 78f092d2fe..0fb1d0bbdc 100644 --- a/Koha/Patron/Modification.pm +++ b/Koha/Patron/Modification.pm @@ -104,7 +104,7 @@ sub approve { # Take care of extended attributes if ( $self->extended_attributes ) { - $extended_attributes = try { decode_json( $self->extended_attributes ) } + $extended_attributes = try { from_json( $self->extended_attributes ) } catch { Koha::Exceptions::Patron::Modification::InvalidData->throw( 'The passed extended_attributes is not valid JSON'); diff --git a/Koha/Patron/Modifications.pm b/Koha/Patron/Modifications.pm index 403b9558c5..5e7ed9efa5 100644 --- a/Koha/Patron/Modifications.pm +++ b/Koha/Patron/Modifications.pm @@ -97,7 +97,7 @@ sub pending { while ( my $row = $sth->fetchrow_hashref() ) { foreach my $key ( keys %$row ) { if ( defined $row->{$key} && $key eq 'extended_attributes' ) { - my $attributes = decode_json( $row->{$key} ); + my $attributes = from_json( $row->{$key} ); my @pending_attributes; foreach my $attr ( @{$attributes} ) { push @pending_attributes,