fix(model): add guarded
This commit is contained in:
parent
8e8f49ae87
commit
8ad3fd087f
6 changed files with 5 additions and 2 deletions
|
@ -15,4 +15,5 @@ use Flarum\Database\AbstractModel;
|
|||
class AccessToken extends AbstractModel
|
||||
{
|
||||
protected $table = 'oauth_access_tokens';
|
||||
protected $guarded = [];
|
||||
}
|
||||
|
|
|
@ -15,4 +15,5 @@ use Flarum\Database\AbstractModel;
|
|||
class AuthorizationCode extends AbstractModel
|
||||
{
|
||||
protected $table = 'oauth_authorization_codes';
|
||||
protected $guarded = [];
|
||||
}
|
||||
|
|
|
@ -15,7 +15,6 @@ use Flarum\Database\AbstractModel;
|
|||
class Client extends AbstractModel
|
||||
{
|
||||
protected $table = 'oauth_clients';
|
||||
|
||||
protected $guarded = [];
|
||||
|
||||
public static function build(string $client_id, string $client_secret, int $user_id)
|
||||
|
|
|
@ -15,4 +15,5 @@ use Flarum\Database\AbstractModel;
|
|||
class Jwt extends AbstractModel
|
||||
{
|
||||
protected $table = 'oauth_jwt';
|
||||
protected $guarded = [];
|
||||
}
|
||||
|
|
|
@ -15,4 +15,5 @@ use Flarum\Database\AbstractModel;
|
|||
class RefreshToken extends AbstractModel
|
||||
{
|
||||
protected $table = 'oauth_refresh_tokens';
|
||||
protected $guarded = [];
|
||||
}
|
||||
|
|
|
@ -15,7 +15,7 @@ use Flarum\Database\AbstractModel;
|
|||
class Scope extends AbstractModel
|
||||
{
|
||||
protected $table = 'oauth_scopes';
|
||||
|
||||
protected $guarded = [];
|
||||
static public function get_path_scope($path = '')
|
||||
{
|
||||
return self::where('resource_path', 'like', $path . '%')->first();
|
||||
|
|
Loading…
Reference in a new issue