diff --git a/server/index.ts b/server/index.ts index b699ead..a1c53c9 100644 --- a/server/index.ts +++ b/server/index.ts @@ -66,15 +66,10 @@ server.use( let measurer = new Measurer(); return { + env, db: ctx.env.DB, - kv: { - cache: ctx.env.cache, - auth: ctx.env.auth, - airtable: ctx.env.airtable, - tutorials: ctx.env.tutorials, - }, + kv: { cache: ctx.env.cache, auth: ctx.env.auth }, waitUntil: ctx.executionCtx.waitUntil.bind(ctx.executionCtx), - env, time: measurer.time.bind(measurer), }; }, diff --git a/types/cloudflare.d.ts b/types/cloudflare.d.ts index 0800d77..f61ff33 100644 --- a/types/cloudflare.d.ts +++ b/types/cloudflare.d.ts @@ -2,8 +2,6 @@ interface RuntimeEnv { auth: KVNamespace; - airtable: KVNamespace; - tutorials: KVNamespace; cache: KVNamespace; DB: D1Database; DSN?: string | undefined; diff --git a/types/sdx.d.ts b/types/sdx.d.ts index 56897b2..fb99dce 100644 --- a/types/sdx.d.ts +++ b/types/sdx.d.ts @@ -20,7 +20,7 @@ declare global { declare module "@remix-run/server-runtime" { export interface AppLoadContext { db: D1Database; - kv: Record<"cache" | "tutorials" | "airtable" | "auth", KVNamespace>; + kv: Record<"cache" | "auth", KVNamespace>; waitUntil(promise: Promise): void; env: Env; time: Measurer["time"]; diff --git a/wrangler.toml b/wrangler.toml index 9bf2cf1..d9601ab 100644 --- a/wrangler.toml +++ b/wrangler.toml @@ -4,9 +4,7 @@ node_compat = true kv_namespaces = [ { binding = "cache", id = "597a3ce0108c42798aeac0044a566e31", preview_id = "cache" }, - { binding = "airtable", id = "7be9035dc2c04b2581e0a85ec1af46bb", preview_id = "airtable@sergiodxa.com" }, { binding = "auth", id = "fda5fdfe90e74e2b82dd0ccd49346c27", preview_id = "auth@sergiodxa.com" }, - { binding = "tutorials", id = "35d8114ec66b41a3b1fb1723df61282f", preview_id = "tutorials@sergiodxa.com" }, ] [[d1_databases]]