Skip to content

Commit dd6054f

Browse files
committed
review fix
1 parent b80d7dc commit dd6054f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/cloudflare/src/cli/populate-cache/populate-cache.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,13 +88,14 @@ export async function populateCache(
8888
switch (name) {
8989
case "d1-next-mode-tag-cache": {
9090
logger.info("\nCreating D1 table if necessary...");
91+
const revalidationsTable = process.env.NEXT_CACHE_D1_REVALIDATIONS_TABLE || "revalidations";
9192

9293
runWrangler(
9394
options,
9495
[
9596
"d1 execute",
9697
"NEXT_CACHE_D1",
97-
`--command "CREATE TABLE IF NOT EXISTS revalidations (tag TEXT NOT NULL, revalidatedAt INTEGER NOT NULL, UNIQUE(tag) ON CONFLICT REPLACE);"`,
98+
`--command "CREATE TABLE IF NOT EXISTS ${JSON.stringify(revalidationsTable)} (tag TEXT NOT NULL, revalidatedAt INTEGER NOT NULL, UNIQUE(tag) ON CONFLICT REPLACE);"`,
9899
],
99100
{ ...populateCacheOptions, logging: "error" }
100101
);

0 commit comments

Comments
 (0)