From: Marius Gavrilescu Date: Sun, 25 Jan 2015 20:37:53 +0000 (+0200) Subject: Actually use AUTH_TIMEOUT X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=10c1364274ab64b4342d2aed34e45edb68e170f4;p=gruntmaster-page.git Actually use AUTH_TIMEOUT --- diff --git a/app.psgi b/app.psgi index 2fcdc00..3d4fe52 100644 --- a/app.psgi +++ b/app.psgi @@ -15,9 +15,9 @@ use constant AUTH_TIMEOUT => 5 * 60; use constant ACCESSLOG_FORMAT => '%{X-Forwarded-For}i|%h %u "%r" %>s %b "%{Referer}i" "%{User-agent}i"'; use constant CONTENT_SECURITY_POLICY => q,default-src 'none'; script-src 'self' www.google-analytics.com; style-src 'self'; img-src 'self'; connect-src 'self'; frame-src free.timeanddate.com,; -my $db = Gruntmaster::Data->connect($ENV{GRUNTMASTER_DSN} // 'dbi:Pg:'); +my $db = Gruntmaster::Data->connect($ENV{GRUNTMASTER_DSN} //' dbi:Pg:'); -tie my %auth, 'Tie::Hash::Expire', {expire_seconds => 300}; +tie my %auth, 'Tie::Hash::Expire', {expire_seconds => AUTH_TIMEOUT}; sub authenticate { my ($user, $pass, $env) = @_;