diff --git a/resources/views/pages/auth/login.blade.php b/resources/views/pages/auth/login.blade.php index b90f2d5..a2b5147 100644 --- a/resources/views/pages/auth/login.blade.php +++ b/resources/views/pages/auth/login.blade.php @@ -108,8 +108,10 @@ public function authenticate() event(new Login(auth()->guard('web'), $this->userModel->where('email', $this->email)->first(), true)); if(session()->get('url.intended') != route('logout.get')){ + session()->regenerate(); redirect()->intended(config('devdojo.auth.settings.redirect_after_auth')); } else { + session()->regenerate(); return redirect(config('devdojo.auth.settings.redirect_after_auth')); } } diff --git a/resources/views/pages/auth/register.blade.php b/resources/views/pages/auth/register.blade.php index ff4afcb..e987a56 100644 --- a/resources/views/pages/auth/register.blade.php +++ b/resources/views/pages/auth/register.blade.php @@ -108,8 +108,10 @@ public function register() } if (session()->get('url.intended') != route('logout.get')) { + session()->regenerate(); redirect()->intended(config('devdojo.auth.settings.redirect_after_auth')); } else { + session()->regenerate(); return redirect(config('devdojo.auth.settings.redirect_after_auth')); } }