Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion components.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{
"$schema": "https://ui.shadcn.com/schema.json",
"style": "new-york",
"rsc": true,
"tsx": true,
Expand Down
1 change: 1 addition & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ export default [
"cypress/**",
"playwright/**",
"k6/**",
"src/db/client/**", // Generated Prisma client files
],
},
];
965 changes: 411 additions & 554 deletions package-lock.json

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
"schema": "src/db/schema.prisma"
},
"dependencies": {
"@prisma/adapter-pg": "^7.1.0",
"@prisma/client": "^7.1.0",
"@prisma/adapter-pg": "^7.4.2",
"@prisma/client": "^7.4.2",
"@radix-ui/react-alert-dialog": "^1.1.6",
"@radix-ui/react-dialog": "^1.1.6",
"@radix-ui/react-dropdown-menu": "^2.1.6",
Expand Down Expand Up @@ -54,8 +54,9 @@
"@types/pg": "^8.15.6",
"@types/react": "^19",
"@types/react-dom": "^19",
"@typescript-eslint/eslint-plugin": "^8.46.1",
"@typescript-eslint/parser": "^8.46.1",
"@typescript-eslint/eslint-plugin": "^8.56.0",
"@typescript-eslint/parser": "^8.56.0",
"baseline-browser-mapping": "^2.10.0",
"cypress": "^14.3.3",
"eslint": "^9.38.0",
"eslint-plugin-prettier": "^5.5.4",
Expand Down
4 changes: 2 additions & 2 deletions prisma.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { defineConfig } from "prisma/config"
import { defineConfig } from "prisma/config";

export default defineConfig({
datasource: {
url: process.env.DATABASE_URL!
url: process.env.DATABASE_URL!,
},
});
14 changes: 7 additions & 7 deletions src/db/prisma.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
// lib/prisma.ts
import { PrismaClient } from "./client"
import { PrismaPg } from "@prisma/adapter-pg"
import { Pool } from "pg"
import { PrismaClient } from "./client";
import { PrismaPg } from "@prisma/adapter-pg";
import { Pool } from "pg";

const globalForPrisma = global as unknown as { prisma: PrismaClient }
const globalForPrisma = global as unknown as { prisma: PrismaClient };

const pool = new Pool({ connectionString: process.env.DATABASE_URL })
const adapter = new PrismaPg(pool)
const pool = new Pool({ connectionString: process.env.DATABASE_URL });
const adapter = new PrismaPg(pool);

export const prisma =
globalForPrisma.prisma ||
new PrismaClient({
adapter,
});

if (process.env.NODE_ENV !== "production") globalForPrisma.prisma = prisma
if (process.env.NODE_ENV !== "production") globalForPrisma.prisma = prisma;
2 changes: 1 addition & 1 deletion src/middleware.ts → src/proxy.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createServerClient } from "@supabase/ssr";
import { NextResponse, type NextRequest } from "next/server";

export async function middleware(request: NextRequest) {
export async function proxy(request: NextRequest) {
return await updateSession(request);
}

Expand Down
Loading