Skip to content

Commit a34814c

Browse files
committed
style(cli): format the check cache
1 parent f741166 commit a34814c

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎packages/cli/src/utils/checkCache.ts‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ function hashTree(dir: string, prefix: string, hash: ReturnType<typeof createHas
4242
);
4343
for (const entry of entries) {
4444
if (SKIPPED_DIRS.has(entry.name)) continue;
45-
if (entry.name === "node_modules") throw new Uncacheable("node_modules can hold code the page runs");
45+
if (entry.name === "node_modules")
46+
throw new Uncacheable("node_modules can hold code the page runs");
4647
const path = join(dir, entry.name);
4748
const name = `${prefix}${entry.name}`;
4849
if (entry.isDirectory()) hashTree(path, `${name}/`, hash);
@@ -58,7 +59,9 @@ export function checkCacheKey(
5859
): string | undefined {
5960
const hash = createHash("sha256").update(`${version}\0`);
6061
const { cache: _cache, ...verdictOptions } = options;
61-
const env = Object.entries(process.env).filter(([name]) => VERDICT_ENV.test(name)).sort();
62+
const env = Object.entries(process.env)
63+
.filter(([name]) => VERDICT_ENV.test(name))
64+
.sort();
6265
hash.update(`${JSON.stringify([verdictOptions, env])}\0`);
6366
try {
6467
hashTree(projectDir, "", hash);

0 commit comments

Comments
 (0)