There was an error while loading. Please reload this page.
1 parent 1b4fc8b commit 0bfd397Copy full SHA for 0bfd397
1 file changed
packages/rstack/bin/rs.js
@@ -3,11 +3,11 @@ import nodeModule from 'node:module';
3
4
// enable on-disk code caching and share its directory with child workers
5
// requires Nodejs >= 22.8.0
6
-const { enableCompileCache } = nodeModule;
+const { enableCompileCache, constants } = nodeModule;
7
if (enableCompileCache) {
8
try {
9
- const { directory } = enableCompileCache();
10
- if (directory) {
+ const { directory, status } = enableCompileCache();
+ if (directory && status === constants.compileCacheStatus.ENABLED) {
11
process.env.NODE_COMPILE_CACHE = directory;
12
}
13
} catch {
0 commit comments