From fe7f158b2ea0194a3f89a21ce426a7cbab515b5c Mon Sep 17 00:00:00 2001 From: Francois Pons Date: Thu, 27 Feb 2003 13:13:15 +0000 Subject: allow choices to return multiple selection. --- URPM/Resolve.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm index ae4d5b4..289fd7c 100644 --- a/URPM/Resolve.pm +++ b/URPM/Resolve.pm @@ -261,8 +261,8 @@ sub resolve_requested { (sort { $a->id <=> $b->id } @chosen_other), (sort { $a->id <=> $b->id } @chosen_bad_locales)); if (!$pkg && $options{callback_choices} && @chosen > 1) { - $pkg = $options{callback_choices}->($urpm, $db, $state, \@chosen); - $pkg or next; #- callback may decide to not continue (or state is already updated). + unshift @properties, map { $_->id } grep { ref $_ } $options{callback_choices}->($urpm, $db, $state, \@chosen); + next; #- always redo according to choices. } $pkg ||= $chosen[0]; !$pkg || $pkg->flag_selected || exists $state->{selected}{$pkg->id} and next; -- cgit v1.2.1