| @@ 31-42 (lines=12) @@ | ||
| 28 | * |
|
| 29 | * @return void |
|
| 30 | */ |
|
| 31 | public function __construct() |
|
| 32 | { |
|
| 33 | if (config('backpack.base.separate_admin_session')) { |
|
| 34 | $this->middleware('guest:'.config('backpack.base.admin_guard.name'), ['except' => 'logout']); |
|
| 35 | } else { |
|
| 36 | $this->middleware('guest'); |
|
| 37 | } |
|
| 38 | ||
| 39 | // Where to redirect users after login / registration. |
|
| 40 | $this->redirectTo = property_exists($this, 'redirectTo') ? $this->redirectTo |
|
| 41 | : config('backpack.base.route_prefix', 'dashboard'); |
|
| 42 | } |
|
| 43 | ||
| 44 | public function guard() |
|
| 45 | { |
|
| @@ 31-41 (lines=11) @@ | ||
| 28 | * |
|
| 29 | * @return void |
|
| 30 | */ |
|
| 31 | public function __construct() |
|
| 32 | { |
|
| 33 | if (config('backpack.base.separate_admin_session')) { |
|
| 34 | $this->middleware('guest:'.config('backpack.base.admin_guard.name'), ['except' => 'logout']); |
|
| 35 | } else { |
|
| 36 | $this->middleware('guest'); |
|
| 37 | } |
|
| 38 | ||
| 39 | // where to redirect after password was reset |
|
| 40 | $this->redirectTo = property_exists($this, 'redirectTo') ? $this->redirectTo : config('backpack.base.route_prefix', 'admin').'/dashboard'; |
|
| 41 | } |
|
| 42 | ||
| 43 | public function guard() |
|
| 44 | { |
|