X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=SL%2FLocale.pm;h=a6756fefeae0d3024ffb68ca6d1521aef13f8e1b;hb=89dd4ca84494de24ac1ecc7bd3b84fdd35e28020;hp=e941f003a964acc207ee3782c08c0af77ee29ccf;hpb=faef45c2e723c9fbc80d1d84b8481367204719b7;p=kivitendo-erp.git diff --git a/SL/Locale.pm b/SL/Locale.pm index e941f003a..a6756fefe 100644 --- a/SL/Locale.pm +++ b/SL/Locale.pm @@ -47,10 +47,14 @@ sub new { my ($type, $country, $NLS_file) = @_; my $self = {}; + $country =~ s|.*/||; + $country =~ s|\.||g; + $NLS_file =~ s|.*/||; + if ($country && -d "locale/$country") { local *IN; $self->{countrycode} = $country; - if (open(IN, "locale/$country/$NLS_file")) { + if (open(IN, "<", "locale/$country/$NLS_file")) { my $code = join("", ); eval($code); close(IN);