Skip to content

Commit

Permalink
wip: remove auth guard setting
Browse files Browse the repository at this point in the history
  • Loading branch information
Hasan Deeb committed Jun 12, 2024
1 parent 3f026a2 commit 809b8c0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions config/naive-crud.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,4 @@
'image_height' => env('NC_IMAGE_MAX_HEIGHT'),
'image_thumbnail' => env('NC_IMAGE_THUMBNAIL', false),
'image_thumbnail_width' => env('NC_IMAGE_THUMBNAIL_WIDTH', 200),
'auth_guard' => env('NC_AUTH_GUARD'),
'auth_admin_guard' => env('NC_AUTH_ADMIN_GUARD'),
];
2 changes: 1 addition & 1 deletion src/Traits/Crud/AuthorizeTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ public function getExportAbility(): array|string

public function resolveUser(): ?User
{
$this->user ??= auth()->guard($this->guard /*?? config('naive-crud.auth_guard')*/)->user();
$this->user ??= auth()->guard($this->guard)->user();

return $this->user;
}
Expand Down

0 comments on commit 809b8c0

Please sign in to comment.