X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/429a7c2179e2c3c4fe9bfcbb52ebb22e55c8519a..53593baa211863fbf66540cf1bcc36c8fb37257f:/SL/MT940.pm diff --git a/SL/MT940.pm b/SL/MT940.pm index dd965deea..2a97e5e79 100644 --- a/SL/MT940.pm +++ b/SL/MT940.pm @@ -24,7 +24,7 @@ sub _join_entries { } sub parse { - my ($class, $file_name) = @_; + my ($class, $file_name, %params) = @_; my ($local_bank_code, $local_account_number, %transaction, @transactions, @lines); my $line_number = 0; @@ -40,7 +40,7 @@ sub parse { my ($active_field); foreach my $line (read_file($file_name)) { chomp $line; - $line = Encode::decode('UTF-8', $line); + $line = Encode::decode($params{charset} // 'UTF-8', $line); $line =~ s{\r+}{}; $line_number++;