Laravel redirects to public/login after logout.or trying to access dashboard

By | May 24, 2018

Below code explains the laravel redirection afterlogout.

After logout if you try to access home/dashboard, it will redirect to following url

http://localhost/schoolidcard/public/index

if we try to access the below url
http://localhost/schoolidcard/public/superadmin/dashboard

it should redirect to http://localhost/schoolidcard/public/superadmin/
instead of this it is redirecting to below path

http://localhost/schoolidcard/public/index

Solution:for redirecting to superadmin/login .Add the below lines of code in the Redirectifauthenticated.php

Changes to…