summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoão Victor Duarte Martins <jvictor@mandriva.com>2010-06-01 17:49:00 +0000
committerJoão Victor Duarte Martins <jvictor@mandriva.com>2010-06-01 17:49:00 +0000
commitf44b570c09c9e6652a332bba2c04770c47924a0a (patch)
tree43597ff232151c3def2fb93ef9e3c36793cecb95
parentdba69715591ac40656aee57e16e38c26c4b24d05 (diff)
downloadmgaonline-f44b570c09c9e6652a332bba2c04770c47924a0a.tar
mgaonline-f44b570c09c9e6652a332bba2c04770c47924a0a.tar.gz
mgaonline-f44b570c09c9e6652a332bba2c04770c47924a0a.tar.bz2
mgaonline-f44b570c09c9e6652a332bba2c04770c47924a0a.tar.xz
mgaonline-f44b570c09c9e6652a332bba2c04770c47924a0a.zip
Syntax cleanup (perl_checker recommendations).
-rwxr-xr-xmdkapplet-add-media-helper10
-rw-r--r--mdkapplet_gui.pm5
-rw-r--r--mdkonline.pm6
3 files changed, 8 insertions, 13 deletions
diff --git a/mdkapplet-add-media-helper b/mdkapplet-add-media-helper
index 48693723..ee346a67 100755
--- a/mdkapplet-add-media-helper
+++ b/mdkapplet-add-media-helper
@@ -103,7 +103,7 @@ my $title = N("Adding an additional package medium");
$product_id or mdkonline::get_product_id();
# Product id data should be used in lowercase.
- $up_product = lc $product_id->{product} unless $up_product;
+ $up_product ||= lc $product_id->{product};
# Sanitizes product command line argument.
unless (exists $product{$up_product}) {
@@ -141,7 +141,7 @@ sub authenticate_callback {
$title,
N("Your Mandriva account does not have %s download subscription enabled.",
mdkonline::translate_product($up_product)),
- $product{$up_product}->{info_url}
+ $product{$up_product}{info_url}
);
}
else {
@@ -153,10 +153,10 @@ sub add_medium_for_product {
my ($product, $email, $passwd) = @_;
my $error = 0;
- my $arch = urpm::cfg::get_arch();
- my @archs = ($arch, if_($arch eq 'x86_64', 'i586'));
+ my $current_arch = urpm::cfg::get_arch();
+ my @archs = ($current_arch, if_($current_arch eq 'x86_64', 'i586'));
- for $arch (@archs) {
+ foreach my $arch (@archs) {
unless ($product->{add_medium}->($email, $passwd, $up_version, $arch)) {
$error = 1;
interactive->vnew->ask_warn(
diff --git a/mdkapplet_gui.pm b/mdkapplet_gui.pm
index df9de9b9..c713b9b7 100644
--- a/mdkapplet_gui.pm
+++ b/mdkapplet_gui.pm
@@ -84,10 +84,7 @@ our @common = (
# List of widgets advertising Powerpack
our $powerpack_ad = [
gtknew('Label_Left',
- text => N('Mandriva Powerpack brings you the best of Linux ' .
- 'experience for desktop: stability and efficiency ' .
- 'of open source solutions together with exclusive ' .
- 'softwares and Mandriva official support.'),
+ text => N("Mandriva Powerpack brings you the best of Linux experience for desktop: stability and efficiency of open source solutions together with exclusive softwares and Mandriva official support."),
@common),
gtknew('HButtonBox',
layout => 'center',
diff --git a/mdkonline.pm b/mdkonline.pm
index f98e6cfa..b818de54 100644
--- a/mdkonline.pm
+++ b/mdkonline.pm
@@ -191,13 +191,11 @@ sub get_product_info {
my %info = (
powerpack => {
name => N("Mandriva PowerPack"),
- description => N("The Mandriva Linux distribution with even " .
- "more softwares and official support."),
+ description => N("The Mandriva Linux distribution with even more softwares and official support."),
},
free => {
name => N("Mandiva Free"),
- description => N("The 100%% Open Source distribution freely " .
- "available."),
+ description => N("The 100%% Open Source distribution freely available."),
},
);
$product ||= lc $product_id->{product};