3
0
Fork 0
This repository has been archived on 2024-11-14. You can view files and clone it, but cannot push or open issues or pull requests.
ThemeParkPlus-Panel/app/Http/Middleware/Authenticate.php

22 lines
464 B
PHP
Raw Permalink Normal View History

2020-02-26 13:59:58 +00:00
<?php
namespace App\Http\Middleware;
use Illuminate\Auth\Middleware\Authenticate as Middleware;
class Authenticate extends Middleware
{
/**
* Get the path the user should be redirected to when they are not authenticated.
*
* @param \Illuminate\Http\Request $request
* @return string
*/
protected function redirectTo($request)
{
if (! $request->expectsJson()) {
return route('login');
}
}
}