I’m trying to have a route that is valid both for guest users and users that are logged in. The hitch is that, if the user is logged in, I still want to know which user she is - so my controller can respond slightly differently.
It appears if I use the “guest” middleware, then logged in users can’t use that route, and if I use the “auth” middleware, obviously, guests can’t access the route.
If I use no middleware at all, then both types of users have access to the route, but auth.user is undefined since the auth middleware wasn’t involved…
Am I forced to use different routes for guests and logged in users?