Support Node.js nightly version in version check (#19837)

This commit is contained in:
fisker Cheung authored and GitHub committed 2026-08-13 07:35:02 +08:00
1 parent fc7954d312
commit 7141699326
1 file changed
+1 -1
+1 -1
View File
@@ -9,7 +9,7 @@ if (typeof nodeModule.enableCompileCache === "function") {
} }
function parseVersion(version) { function parseVersion(version) {
var parts = version.split(".", 3); var parts = version.split("-", 1)[0].split(".", 3);
return { return {
major: Number(parts[0]), major: Number(parts[0]),
minor: Number(parts[1]) || 0, minor: Number(parts[1]) || 0,