Fixed Wrong IP being loged
This commit is contained in:
@@ -48,9 +48,11 @@ export const Login = () => {
|
||||
return;
|
||||
}
|
||||
|
||||
console.log("data", data);
|
||||
const ip = await fetch("https://api.ipify.org/?format=json")
|
||||
.then((res) => res.json())
|
||||
.then((data) => data.ip);
|
||||
|
||||
await logAction("LOGIN");
|
||||
await logAction("LOGIN", { ip });
|
||||
redirect(searchParams.get("redirect") || "/");
|
||||
} catch (error) {
|
||||
showBoundary(error);
|
||||
|
||||
Reference in New Issue
Block a user