app and db schema - region rename, hostname move

This commit is contained in:
Francis Cao 2025-04-24 22:42:33 -07:00
parent 5dccca0c3f
commit 12b8ac4272
19 changed files with 11252 additions and 89 deletions

View file

@ -78,8 +78,10 @@ export async function POST(request: Request) {
}
// Client info
const { ip, userAgent, device, browser, os, country, subdivision1, subdivision2, city } =
await getClientInfo(request, payload);
const { ip, userAgent, device, browser, os, country, region, city } = await getClientInfo(
request,
payload,
);
// Bot check
if (!process.env.DISABLE_BOT_CHECK && isbot(userAgent)) {
@ -109,15 +111,13 @@ export async function POST(request: Request) {
await createSession({
id: sessionId,
websiteId,
hostname,
browser,
os,
device,
screen,
language,
country,
subdivision1,
subdivision2,
region,
city,
});
} catch (e: any) {
@ -210,8 +210,7 @@ export async function POST(request: Request) {
screen,
language,
country,
subdivision1,
subdivision2,
region,
city,
tag,
createdAt,