expiry maybe defined even if it is not provided as an argument
authorMatthias Förste <foerste@schlittermann.de>
Tue, 12 Jul 2011 10:58:31 +0200
changeset 9 4227cf8872b8
parent 8 f5e94db98601
child 10 059036ddb06d
expiry maybe defined even if it is not provided as an argument
lib/Ius/Dav/Htpasswd.pm
--- a/lib/Ius/Dav/Htpasswd.pm	Thu Jul 07 14:18:54 2011 +0200
+++ b/lib/Ius/Dav/Htpasswd.pm	Tue Jul 12 10:58:31 2011 +0200
@@ -93,7 +93,7 @@
             unless defined $conf->{$_};
     }
 
-    $expiry = $conf->{expiry} unless defined $expiry;
+    $expiry = $conf->{expiry} unless defined $expiry and $expiry ne '';
     die 'Invalid input' unless validate $conf, $user, $expiry;
 
     my $at_cmd = "at now + " . 24 * 60 * $expiry . " minutes";