summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2010-01-27 14:59:47 +0000
committerThierry Vignaud <tv@mandriva.org>2010-01-27 14:59:47 +0000
commit9b0d12be755b16025bb468f3cb7731ce0c754562 (patch)
treeb9fa29be96c6002c96301cc613497183e96f3e92
parent2ba06a99d61af9c2865e258fccfb4f84f16df4ff (diff)
downloadmgaonline-9b0d12be755b16025bb468f3cb7731ce0c754562.tar
mgaonline-9b0d12be755b16025bb468f3cb7731ce0c754562.tar.gz
mgaonline-9b0d12be755b16025bb468f3cb7731ce0c754562.tar.bz2
mgaonline-9b0d12be755b16025bb468f3cb7731ce0c754562.tar.xz
mgaonline-9b0d12be755b16025bb468f3cb7731ce0c754562.zip
(update_backport_media) simplify
-rwxr-xr-xmdkapplet7
1 files changed, 5 insertions, 2 deletions
diff --git a/mdkapplet b/mdkapplet
index ee8a75c0..ff291874 100755
--- a/mdkapplet
+++ b/mdkapplet
@@ -597,8 +597,11 @@ sub update_backport_media {
my ($urpm) = @_;
# update inactive backport media:
my @inactive_backport_media = Rpmdrake::open_db::get_inactive_backport_media($urpm);
- log::explanations("updating inactive backport media " . join(', ', @inactive_backport_media)) if @inactive_backport_media;
- run_program::run('urpmi.update', if_($root, "--urpmi-root=$root"), $_) foreach @inactive_backport_media;
+ return if !@inactive_backport_media;
+ log::explanations("updating inactive backport media " . join(', ', @inactive_backport_media));
+ foreach (@inactive_backport_media) {
+ run_program::run('urpmi.update', if_($root, "--urpmi-root=$root"), $_);
+ }
}
sub silentCheck() {