mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-10-09 03:26:38 +08:00
SessionRefresh log
This commit is contained in:
parent
b5e01e1fd9
commit
f871e2b8bb
@ -39,6 +39,7 @@ export const authOptions: NextAuthOptions = {
|
|||||||
console.error("Email is required for sign in");
|
console.error("Email is required for sign in");
|
||||||
return false; // Prevent sign-in
|
return false; // Prevent sign-in
|
||||||
}
|
}
|
||||||
|
console.log("Sign-In: ",user.email);
|
||||||
const dateKey = new Date().toISOString().slice(0, 7); // "YYYY-MM"
|
const dateKey = new Date().toISOString().slice(0, 7); // "YYYY-MM"
|
||||||
await incrementSignInCount(user.email, dateKey);
|
await incrementSignInCount(user.email, dateKey);
|
||||||
return true;
|
return true;
|
||||||
@ -60,6 +61,7 @@ export const authOptions: NextAuthOptions = {
|
|||||||
session.error = "Email is missing";
|
session.error = "Email is missing";
|
||||||
return session; // Return the modified session
|
return session; // Return the modified session
|
||||||
}
|
}
|
||||||
|
console.log("Session-Refresh: ",token.email);
|
||||||
const dateKey = new Date().toISOString().slice(0, 7); // "YYYY-MM"
|
const dateKey = new Date().toISOString().slice(0, 7); // "YYYY-MM"
|
||||||
await incrementSessionRefreshCount(token.email, dateKey);
|
await incrementSessionRefreshCount(token.email, dateKey);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user