From db3954aabd399da61bbf215f5d0142c0eb03b8eb Mon Sep 17 00:00:00 2001 From: Joshua Ferraro Date: Sun, 25 Nov 2007 19:41:15 -0600 Subject: [PATCH] allow timeout to be specified in days Signed-off-by: Joshua Ferraro --- C4/Auth.pm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/C4/Auth.pm b/C4/Auth.pm index 300a9ed01b..56598120e3 100755 --- a/C4/Auth.pm +++ b/C4/Auth.pm @@ -380,8 +380,11 @@ sub checkauth { my $dbh = C4::Context->dbh; my $timeout = C4::Context->preference('timeout'); - $timeout = 600 unless $timeout; - + # days + if ($timeout =~ /(\d*)[dD]/) { + $timeout = $1 * 86400; + }; + $timeout = 600 unless $timeout; # If Version syspref is unavailable, it means Koha is beeing installed, # and so we must redirect to OPAC maintenance page or to the WebInstaller -- 2.39.5