Skip to content

Commit

Permalink
Update UserLogoutController.php
Browse files Browse the repository at this point in the history
  • Loading branch information
bobimicroweber committed Feb 16, 2022
1 parent 037744b commit 756096d
Showing 1 changed file with 6 additions and 1 deletion.
Expand Up @@ -5,6 +5,7 @@
use App\Http\Resources\User\UserResource;
use Illuminate\Http\Request;
use Illuminate\Routing\Controller;
use Illuminate\Support\Facades\Auth;
use MicroweberPackages\App\Http\Middleware\SameSiteRefererMiddleware;

class UserLogoutController extends Controller
Expand Down Expand Up @@ -42,7 +43,11 @@ public function index(Request $request)

public function submit(Request $request)
{
return logout();
Auth::logout();

$url = site_url();

return app()->url_manager->redirect($url);
}

}

0 comments on commit 756096d

Please sign in to comment.