mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Also autocreate session folder in debug mode
This commit is contained in:
parent
843ddd6d36
commit
5aff618109
1 changed files with 5 additions and 0 deletions
|
@ -494,7 +494,12 @@ class CakeSession {
|
|||
|
||||
if (!empty($sessionConfig['handler'])) {
|
||||
$sessionConfig['ini']['session.save_handler'] = 'user';
|
||||
} elseif (!empty($sessionConfig['session.save_path']) && Configure::read('debug')) {
|
||||
if (!is_dir($sessionConfig['session.save_path'])) {
|
||||
mkdir($sessionConfig['session.save_path'], 0775, true);
|
||||
}
|
||||
}
|
||||
|
||||
if (!isset($sessionConfig['ini']['session.gc_maxlifetime'])) {
|
||||
$sessionConfig['ini']['session.gc_maxlifetime'] = $sessionConfig['timeout'] * 60;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue