From: Jos I. Boumans Date: Sun, 26 Apr 2009 02:20:37 +0000 (-0500) Subject: [PATCH] Update Term::UI to 0.20 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=46ad78bae1143b11df6e542008abadd9b3e1583b;p=p5sagit%2Fp5-mst-13.2.git [PATCH] Update Term::UI to 0.20 --- diff --git a/lib/Term/UI.pm b/lib/Term/UI.pm index 4b20faa..136f75b 100644 --- a/lib/Term/UI.pm +++ b/lib/Term/UI.pm @@ -11,7 +11,7 @@ use strict; BEGIN { use vars qw[$VERSION $AUTOREPLY $VERBOSE $INVALID]; $VERBOSE = 1; - $VERSION = '0.18'; + $VERSION = '0.20'; $INVALID = loc('Invalid selection, please try again: '); } @@ -147,7 +147,7 @@ sub get_reply { ### so this choice is the default? add it to 'prompt_add' ### so we can construct a "foo? [DIGIT]" type prompt - $prompt_add = $i if $choice eq $args->{default}; + $prompt_add = $i if (defined $args->{default} and $choice eq $args->{default}); ### create a "DIGIT> choice" type line $args->{print_me} .= sprintf "\n%3s> %-s", $i, $choice;