Fix: Redirect to dashboard after login
The app was incorrectly redirecting to a 404 page after login. This commit fixes the redirect to the dashboard after a successful login.
This commit is contained in:
parent
9a2f18c74e
commit
af6bfe3177
@ -47,8 +47,8 @@ const LoginForm = ({ isLoading, setIsLoading }: LoginFormProps) => {
|
||||
description: "Bem-vindo de volta!"
|
||||
});
|
||||
|
||||
// Redirecionamento para o dashboard após login bem-sucedido
|
||||
navigate('/dashboard');
|
||||
// Corrigir o redirecionamento para a rota principal "/"
|
||||
navigate('/');
|
||||
} else {
|
||||
toast({
|
||||
title: "Falha no login",
|
||||
|
||||
@ -1,8 +1,7 @@
|
||||
|
||||
import { useLocation } from "react-router-dom";
|
||||
import { useLocation, Link } from "react-router-dom";
|
||||
import { useEffect } from "react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Link } from "react-router-dom";
|
||||
|
||||
const NotFound = () => {
|
||||
const location = useLocation();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user