- Fixed the all() function of session

- Defined default session cookie to 12hours
This commit is contained in:
Dave Mc Nicoll committed 2020-05-20 15:34:12 -04:00
1 parent 128363c476
commit 754349f523
2 files changed
+6 -1

No files matched your search

+5
View File
@@ -32,6 +32,11 @@ class Session
{
$_SESSION = [];
}
public static function all() : array
{
return $_SESSION;
}
public static function start(array $options, Cookie $cookie, string $savePath) : void
{
+1 -1
View File
@@ -16,7 +16,7 @@ class SessionMiddleware implements MiddlewareInterface
'domain' => null,
'secure' => false,
'httponly' => true,
'lifetime' => 28800, # A day of work ~ 8 hours
'lifetime' => 43200, # A half-day
'samesite' => "",
];