summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2003-05-12 15:44:07 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2003-05-12 15:44:07 +0000
commit19051cd51e0c7c13012869a6e7645df8a2119089 (patch)
treefc0c07da91ce8d71a0701ad9e9292d4fa6aa815e /perl-install
parentc7b16f7f897ab6b2da997faa3c422d688e1774fc (diff)
downloaddrakx-backup-do-not-use-19051cd51e0c7c13012869a6e7645df8a2119089.tar
drakx-backup-do-not-use-19051cd51e0c7c13012869a6e7645df8a2119089.tar.gz
drakx-backup-do-not-use-19051cd51e0c7c13012869a6e7645df8a2119089.tar.bz2
drakx-backup-do-not-use-19051cd51e0c7c13012869a6e7645df8a2119089.tar.xz
drakx-backup-do-not-use-19051cd51e0c7c13012869a6e7645df8a2119089.zip
use matched values only if matching did success
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/any.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm
index b03ee9691..a2b674f01 100644
--- a/perl-install/any.pm
+++ b/perl-install/any.pm
@@ -633,7 +633,7 @@ sub selectLanguage {
$lang = first(lang::l2location($lang))."|$lang";
my %name2l = map { lang::l2name($_) => $_ } lang::list_langs();
- my $listval2val = sub { $_[0] =~ /\|(.*)/; $1 };
+ my $listval2val = sub { $1 if $_[0] =~ /\|(.*)/ };
my @langs = map { my $l = $_; map { [ "$_|$l", $_, $l ] } lang::l2location($l) } lang::list_langs();
#- since gtk version will use images (function image2f) we need to sort differently
@@ -649,7 +649,7 @@ when your installation is complete and you restart your system.")),
$in->ask_from_($common,
[ { val => \$lang, separator => '|',
if_($using_images, image2f => sub { $name2l{$_[0]} =~ /^[a-z]/ ? ('', "langs/lang-$name2l{$_[0]}") : $_[0] }),
- format => sub { $_[0] =~ /(.*\|)(.*)/; $1.lang::l2name($2) },
+ format => sub { $1.lang::l2name($2) if $_[0] =~ /(.*\|)(.*)/ },
list => \@langs, sort => 0 },
if_($langs_, if_($::isInstall,
{ val => \$in->{locale}{utf8}, type => 'bool', text => N("Use Unicode by default"), advanced => 1 }),