mirror of
https://github.com/flarum/core.git
synced 2025-08-06 08:27:42 +02:00
Fix some incorrect attribute names
This commit is contained in:
@@ -58,7 +58,7 @@ class CollectGarbage implements Middleware
|
||||
|
||||
$time = Carbon::now()->timestamp;
|
||||
|
||||
AccessToken::whereRaw('last_activity <= ? - lifetime', [$time])->delete();
|
||||
AccessToken::whereRaw('last_activity_at <= ? - lifetime_seconds', [$time])->delete();
|
||||
|
||||
$earliestToKeep = date('Y-m-d H:i:s', $time - 24 * 60 * 60);
|
||||
|
||||
|
@@ -33,12 +33,12 @@ class Rememberer
|
||||
|
||||
public function remember(ResponseInterface $response, AccessToken $token)
|
||||
{
|
||||
$token->lifetime = 5 * 365 * 24 * 60 * 60; // 5 years
|
||||
$token->lifetime_seconds = 5 * 365 * 24 * 60 * 60; // 5 years
|
||||
$token->save();
|
||||
|
||||
return FigResponseCookies::set(
|
||||
$response,
|
||||
$this->cookie->make(self::COOKIE_NAME, $token->id, $token->lifetime)
|
||||
$this->cookie->make(self::COOKIE_NAME, $token->token, $token->lifetime_seconds)
|
||||
);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user