We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents e59af84 + 8a6f823 commit 266c38aCopy full SHA for 266c38a
lib/utils/useDatabase.ts
@@ -1,5 +1,4 @@
1
import { sql } from "drizzle-orm";
2
-import { upstashCache } from "drizzle-orm/cache/upstash";
3
import { drizzle } from "drizzle-orm/node-postgres";
4
import { err, ok, type Result } from "neverthrow";
5
import { cache } from "react";
@@ -34,11 +33,6 @@ export async function getDatabaseForOwner(ownerId: string): Promise<Database> {
34
33
const sslMode = process.env.DATABASE_SSL === "true" ? "?sslmode=require" : "";
35
36
return drizzle(`${process.env.DATABASE_URL}/${databaseName}${sslMode}`, {
37
- cache: upstashCache({
38
- url: process.env.UPSTASH_REDIS_REST_URL!,
39
- token: process.env.UPSTASH_REDIS_REST_TOKEN!,
40
- global: true,
41
- }),
42
schema,
43
});
44
}
0 commit comments