I get this error when compiling 11.
INFO] Running with Node @ node /Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:2256 if (path.existsSync(url)) { ^ TypeError: path.existsSync is not a function at Function.req.load (/Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:2256:18) at resume (/Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:1280:37) at Object.context.require (/Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:1479:25) at requirejs (/Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:1681:24) at /Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:9770:1 at Object.<anonymous> (/Users/qcastel/Development/GIT/openam-sustaining/openam-authentication/deviceprint/scripts/src/main/requirejs/r.js:9820:2) at Module._compile (module.js:434:26) at Object.Module._extensions..js (module.js:452:10) at Module.load (module.js:355:32) at Function.Module._load (module.js:310:12)
A simple fix is to add this
- if (path.existsSync(url)) { + if (fs.existsSync ? fs.existsSync(url) : path.existsSync(url)) {
This solution is part of the OPENAM-5508 fix, so 12.0.1 contains the same change.
- is related to
-
OPENAM-5545 Build failure when Node.js is used over Rhino
-
- Resolved
-