When a user tries to access a page for which he has no rights, he gets an ugly AuthenticationException :
/home/laurentdev/git_repo/Sites/ChallengeInterPromo17/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php
*/
public function authenticate()
{
if (! is_null($user = $this->user())) {
return $user;
}
throw new AuthenticationException;
}
Instead, he should be redirected to the "unauthorized" route.
Bonus : a new Dusk test should be implemented regarding this issue.
When a user tries to access a page for which he has no rights, he gets an ugly AuthenticationException :
/home/laurentdev/git_repo/Sites/ChallengeInterPromo17/vendor/laravel/framework/src/Illuminate/Auth/GuardHelpers.php
Instead, he should be redirected to the "unauthorized" route.
Bonus : a new Dusk test should be implemented regarding this issue.