summaryrefslogtreecommitdiffstats
path: root/urpm/get_pkgs.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-07-08 20:22:28 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-07-08 20:22:28 +0000
commitaa55d788ed9d68828b7eb597b4b2a32edb077672 (patch)
tree24f03d5a0140f967d560080bb686340c0b4b9994 /urpm/get_pkgs.pm
parentbbbc64f7735eaeb7f5163317f5ddfdb71f6f8615 (diff)
downloadurpmi-aa55d788ed9d68828b7eb597b4b2a32edb077672.tar
urpmi-aa55d788ed9d68828b7eb597b4b2a32edb077672.tar.gz
urpmi-aa55d788ed9d68828b7eb597b4b2a32edb077672.tar.bz2
urpmi-aa55d788ed9d68828b7eb597b4b2a32edb077672.tar.xz
urpmi-aa55d788ed9d68828b7eb597b4b2a32edb077672.zip
now, get rid of blist->{list} :)
Diffstat (limited to 'urpm/get_pkgs.pm')
-rw-r--r--urpm/get_pkgs.pm9
1 files changed, 3 insertions, 6 deletions
diff --git a/urpm/get_pkgs.pm b/urpm/get_pkgs.pm
index ceef8e66..6e3ebfc4 100644
--- a/urpm/get_pkgs.pm
+++ b/urpm/get_pkgs.pm
@@ -120,11 +120,7 @@ sub selected2local_and_blists {
$pkgs{$id_map{$id}} = $pkg;
}
}
- if (%pkgs) {
- my $blist = { medium => $medium, pkgs => \%pkgs };
- $blist->{list} = { map { $_ => urpm::blist_pkg_to_url($blist, $pkgs{$_}) } keys %pkgs };
- $blist;
- } else { () }
+ %pkgs ? { medium => $medium, pkgs => \%pkgs } : ();
} (@{$urpm->{media} || []});
if (@remaining_ids) {
@@ -142,7 +138,8 @@ sub _create_old_list_from_blists {
[ map {
my $medium = $_;
my ($blist) = grep { $_->{medium} == $medium } @$blists;
- $blist->{list};
+
+ { map { $_ => urpm::blist_pkg_to_url($blist, $blist->{pkgs}{$_}) } keys %{$blist->{pkgs}} };
} @$media ];
}