aboutsummaryrefslogtreecommitdiff
path: root/app/Controllers/authController.php
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2016-12-24 17:32:11 +0100
committerGravatar GitHub <noreply@github.com> 2016-12-24 17:32:11 +0100
commit02ac8d563db25aea8f7ec983b67061129536d457 (patch)
treea6756b29a7d9cf92221d2cd737a5a06db95bb110 /app/Controllers/authController.php
parent7ae60ff0cc577997b9b754966a0f52649077b744 (diff)
parente99a6b815290da614fe39658b6c76de8a9d16641 (diff)
Merge pull request #1397 from Alkarex/cookieDuration
Option for cookie duration
Diffstat (limited to 'app/Controllers/authController.php')
-rw-r--r--app/Controllers/authController.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/Controllers/authController.php b/app/Controllers/authController.php
index 9decba431..1398e4e49 100644
--- a/app/Controllers/authController.php
+++ b/app/Controllers/authController.php
@@ -113,6 +113,10 @@ class FreshRSS_auth_Controller extends Minz_ActionController {
$file_mtime = @filemtime(PUBLIC_PATH . '/scripts/bcrypt.min.js');
Minz_View::appendScript(Minz_Url::display('/scripts/bcrypt.min.js?' . $file_mtime));
+ $conf = Minz_Configuration::get('system');
+ $limits = $conf->limits;
+ $this->view->cookie_days = round($limits['cookie_duration'] / 86400, 1);
+
if (Minz_Request::isPost()) {
$nonce = Minz_Session::param('nonce');
$username = Minz_Request::param('username', '');