d
This commit is contained in:
parent
e770e412ad
commit
240b1ef3cc
@ -2,9 +2,9 @@ import { Ionicons } from "@expo/vector-icons";
|
||||
import { router } from "expo-router";
|
||||
import { useState } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { ActivityIndicator, StyleSheet, TextInput, TouchableOpacity, View } from "react-native";
|
||||
import { ActivityIndicator, Alert, StyleSheet, TextInput, TouchableOpacity, View } from "react-native";
|
||||
import { useAuth } from "../../contexts/auth-context";
|
||||
import { fetchApi } from "../../lib/server-api-util";
|
||||
import { API_ENDPOINT, fetchApi } from "../../lib/server-api-util";
|
||||
import { User } from "../../types/user";
|
||||
import { ThemedText } from "../ThemedText";
|
||||
|
||||
@ -52,6 +52,7 @@ const Login = ({ updateUrlParam, setError, setShowPassword, showPassword }: Logi
|
||||
router.replace('/user-message');
|
||||
}
|
||||
} catch (error) {
|
||||
Alert.alert("API_ENDPOINT", API_ENDPOINT);
|
||||
const errorMessage = error instanceof Error ? error.message : t('auth.login.loginError', { ns: 'login' });
|
||||
setError(errorMessage);
|
||||
} finally {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user