Skip to content

Commit 7588b65

Browse files
committed
feat: add macroable guards
1 parent c50c6cb commit 7588b65

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

src/Guards/AuthenticationGuard.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
use Auth0\SDK\Utility\HttpResponse;
1414
use Illuminate\Auth\Events\{Login, Logout};
1515
use Illuminate\Contracts\Auth\Authenticatable;
16+
use Illuminate\Support\Traits\Macroable;
1617

1718
use Throwable;
1819

@@ -26,7 +27,9 @@
2627
* @api
2728
*/
2829
final class AuthenticationGuard extends GuardAbstract implements AuthenticationGuardContract
29-
{
30+
{
31+
use Macroable;
32+
3033
/**
3134
* @var string
3235
*/

src/Guards/AuthorizationGuard.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
use Auth0\Laravel\UserProviderContract;
99
use Auth0\SDK\Utility\HttpResponse;
1010
use Illuminate\Contracts\Auth\Authenticatable;
11+
use Illuminate\Support\Traits\Macroable;
1112

1213
use function is_array;
1314
use function is_string;
@@ -19,6 +20,8 @@
1920
*/
2021
final class AuthorizationGuard extends GuardAbstract implements AuthorizationGuardContract
2122
{
23+
use Macroable;
24+
2225
public function find(): ?CredentialEntityContract
2326
{
2427
if ($this->isImpersonating()) {

0 commit comments

Comments
 (0)