Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
StyleCIBot committed Jan 10, 2025
1 parent 028e73e commit b641b5e
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 10 deletions.
12 changes: 6 additions & 6 deletions config/nova-impersonate.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@
/*
* false (nova path), true or <url>
*/
'redirect_back' => true,
'redirect_back' => true,
/*
* Redirect path
*/
'redirect_to' => '/',
'redirect_to' => '/',
/*
* Set true to record impersonation actions in Nova's action_events table
* Attach the `Laravel\Nova\Actions\Actionable` trait to the `User` Eloquent model
Expand All @@ -38,15 +38,15 @@
/*
* Bind on key press to impersonate user in details page
*/
'key_down' => 'i',
'key_down' => 'i',
/*
* Middleware used for nova-impersonate routes
*/
'middleware' => [
'middleware' => [
/*
* Middleware used for nova-impersonate routes
*/
'base' => 'web',
'base' => 'web',
/*
* Extra middleware used for leave route
*/
Expand All @@ -55,7 +55,7 @@
/*
* Leave impersonate before impersonating a user
*/
'leave_before_impersonate' => false,
'leave_before_impersonate' => false,
/*
* Use a custom impersonation manager instead of the default 404labfr impersonate package.
* E.g. \App\Services\ImpersonateService - implement Contracts\Impersonate.
Expand Down
1 change: 0 additions & 1 deletion src/Http/Middleware/Impersonate.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ public function handle($request, $next)

! Str::contains($request->path(), 'nova-api')
) {

/** @var Response $response * */
$content = $response->getContent();

Expand Down
6 changes: 3 additions & 3 deletions src/Impersonate.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class Impersonate extends Field
public $textAlign = 'center';
public $component = 'impersonate-field';
public $meta = [
'hideText' => true,
'hideText' => true,
'redirect_to' => '/',
'enable_multi_guard' => false,
'impersonator_guards' => ['web'],
Expand Down Expand Up @@ -52,8 +52,8 @@ public function __construct($user = null)
'key_down' => config('nova-impersonate.key_down'),
'redirect_to' => config('nova-impersonate.redirect_to'),
'enable_multi_guard' => config('nova-impersonate.enable_multi_guard'),
'impersonator_guards' => config('nova-impersonate.impersonator_guards'),
'default_impersonator_guard' => config('nova-impersonate.default_impersonator_guard'),
'impersonator_guards' => config('nova-impersonate.impersonator_guards'),
'default_impersonator_guard' => config('nova-impersonate.default_impersonator_guard'),
'impersonate_target_name' => $user->name ?? $user->email ?? null,
]);
}
Expand Down

0 comments on commit b641b5e

Please sign in to comment.