From 3f2a49b697a6eb5ff8db78c05c65070b46bb75a6 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 3 Apr 2011 16:54:40 +0200 Subject: Use confess instead of return undef, Test::Exception for App::Raps2::Password test --- lib/App/Raps2/UI.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/App/Raps2/UI.pm') diff --git a/lib/App/Raps2/UI.pm b/lib/App/Raps2/UI.pm index 43abf29..427270c 100644 --- a/lib/App/Raps2/UI.pm +++ b/lib/App/Raps2/UI.pm @@ -7,6 +7,7 @@ use 5.010; use base 'Exporter'; +use Carp qw(confess); use POSIX; our @EXPORT_OK = (); @@ -63,7 +64,7 @@ sub read_pw { $term->setattr(0, POSIX::TCSANOW); if ($verify and $in1 ne $in2) { - return undef; + confess('Input lines did not match'); } chomp $in1; -- cgit v1.2.3