Bug 25078: Fix encoding issue with db_revs output
From `perldoc -f open`: The scalars for in-memory files are treated as octet strings: unless the file is being opened with truncation the scalar may not contain any code points over 0xFF. So $out need to be decoded first in order to be used in other Perl strings Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
parent
005f20507d
commit
25dda58f04
1 changed files with 2 additions and 1 deletions
|
@ -20,7 +20,7 @@ package C4::Installer;
|
|||
use Modern::Perl;
|
||||
|
||||
use Try::Tiny;
|
||||
use Encode qw( encode is_utf8 );
|
||||
use Encode qw( encode decode is_utf8 );
|
||||
use DBIx::RunSQL;
|
||||
use YAML::XS;
|
||||
use C4::Context;
|
||||
|
@ -744,6 +744,7 @@ sub update {
|
|||
};
|
||||
|
||||
close $outfh;
|
||||
$out = decode('UTF-8', $out);
|
||||
|
||||
my $db_entry = {
|
||||
bug_number => $db_rev->{bug_number},
|
||||
|
|
Loading…
Reference in a new issue