mirror of
https://github.com/flarum/framework.git
synced 2025-01-19 18:12:59 +08:00
Fixes logging in with access token (#1605)
Seems the created_at column has no default value. This was always the case, at least that's what I can tell from a clean install and no migrations changing that default value. ``` $table->timestamp('created_at'); ```
This commit is contained in:
parent
5f5e1c512c
commit
a03f243ca5
|
@ -48,6 +48,7 @@ class AccessToken extends AbstractModel
|
||||||
|
|
||||||
$token->token = str_random(40);
|
$token->token = str_random(40);
|
||||||
$token->user_id = $userId;
|
$token->user_id = $userId;
|
||||||
|
$token->created_at = Carbon::now();
|
||||||
$token->last_activity_at = Carbon::now();
|
$token->last_activity_at = Carbon::now();
|
||||||
$token->lifetime_seconds = $lifetime;
|
$token->lifetime_seconds = $lifetime;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user