user(); $this->app->setLocale($this->languages->resolveFor($user instanceof User ? $user : null)); return $next($request); } }