Skip to content

Commit

Permalink
feat: add ip record in telemetry
Browse files Browse the repository at this point in the history
  • Loading branch information
moonrailgun committed Nov 27, 2023
1 parent de844db commit 7b519b1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
-- AlterTable
ALTER TABLE "TelemetrySession" ADD COLUMN "ip" VARCHAR(45);
1 change: 1 addition & 0 deletions prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@ model TelemetrySession {
hostname String? @db.VarChar(100)
browser String? @db.VarChar(20)
os String? @db.VarChar(20)
ip String? @db.VarChar(45)
country String? @db.Char(2)
subdivision1 String? @db.VarChar(20)
subdivision2 String? @db.VarChar(50)
Expand Down
1 change: 1 addition & 0 deletions src/server/model/telemetry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ async function findSession(req: Request, url: string) {
hostname,
browser,
os,
ip,
country,
subdivision1,
subdivision2,
Expand Down

0 comments on commit 7b519b1

Please sign in to comment.