diff options
author | Guilhem Moulin <guilhem.moulin@fripost.org> | 2012-05-03 18:18:55 +0200 |
---|---|---|
committer | Guilhem Moulin <guilhem.moulin@fripost.org> | 2012-05-03 18:18:55 +0200 |
commit | b0460b1b8fb61569d20cbd4ac75ae6976bd34a92 (patch) | |
tree | a95c60c0f6705d73558e00b3afa3e0006dfb65a2 /lib/Fripost/Prompt.pm | |
parent | eea26843500c7d12f0ee2e9e89d80953d5f7276f (diff) |
‘IO::Prompt’ is deprecacted; Migrating to ‘IO::Prompter’ (by the same author).
Diffstat (limited to 'lib/Fripost/Prompt.pm')
-rwxr-xr-x | lib/Fripost/Prompt.pm | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/Fripost/Prompt.pm b/lib/Fripost/Prompt.pm index 95ea7ea..07a1c0b 100755 --- a/lib/Fripost/Prompt.pm +++ b/lib/Fripost/Prompt.pm @@ -14,7 +14,7 @@ our $VERSION = '0.01'; use Data::Dumper; use Email::Valid; use Exporter; -use IO::Prompt; +use IO::Prompter; use Fripost::Password qw/mkpasswd/; our @EXPORT = qw(confirm confirm_or_abort fix_username prompt_email prompt_password); @@ -23,13 +23,13 @@ our @ISA = qw(Exporter); sub confirm { my ($msg) = @_; $msg //= "Is this OK? [no will abort] "; - return prompt $msg, -ynt; + return prompt $msg, -yn; } sub confirm_or_abort { my ($msg) = @_; $msg //= "Is this OK? [no will abort] "; - my $confirmed = prompt $msg, -ynt; + my $confirmed = prompt $msg, -yn; unless ($confirmed) { say "User aborted"; exit 1; @@ -72,8 +72,8 @@ sub prompt_password { my $password; do { - $password = prompt $msg, -e => '*'; - my $confirm = prompt $msg2, -e => '*'; + $password = prompt $msg, -echo => '*'; + my $confirm = prompt $msg2, -echo => '*'; unless ($password eq $confirm) { undef $password; say "Passwords do not match"; |