fisayoafolayan / laravel-multiple-auth

A simple implementation of multiple authentication in Laravel. To follow along, this application has been documented as an article on Pusher blog.
81 stars 60 forks source link

For Custom guard 'Admin' and 'Writer' logout is not clearing sessions when remember me is checked #3

Closed asamamun closed 4 years ago

asamamun commented 5 years ago

to resolve the issue i have added: public function logout(Request $request) { $this->guard()->logout(); //custom code Auth::guard('admin')->logout(); Auth::guard('writer')->logout(); $request->session()->flush(); $request->session()->regenerate(); //custom code end
$request->session()->invalidate(); return $this->loggedOut($request) ?: redirect('/'); } in Illuminate\Foundation\Auth\AuthenticatesUsers.php

fisayoafolayan commented 4 years ago

Hello @asamamun,

Unfortunately, I can't replicate this bug locally. Please do submit a PR if the problem still persists.

Thanks for raising the issue 👍