auth logging

This commit is contained in:
Jake Kasper
2025-08-21 13:05:16 -05:00
parent be4951153c
commit 8b21687166
3 changed files with 16 additions and 1 deletions

View File

@@ -21,10 +21,15 @@ const Login = () => {
} = useForm();
const onSubmit = async (data) => {
console.log('Login form submitted:', data.email);
const result = await login(data);
console.log('Login result:', result);
if (result.success) {
console.log('Login successful, navigating to:', from);
navigate(from, { replace: true });
} else {
console.log('Login failed, showing error:', result.error);
setError('root', {
type: 'manual',
message: result.error