mirror of
https://github.com/nodejs/node.git
synced 2026-11-29 14:27:57 -05:00
lib: refactor bootstrap_node.js regular expression
* use `+` instead of `*` where one-or-more is required * switch from String.prototype.match() to RegExp.prototype.test() PR-URL: https://github.com/nodejs/node/pull/10749 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Jackson Tian <shyvo1987@gmail.com>
This commit is contained in:
1 parent
06acf88117
commit
4de7b03a7d
1 file changed
+1
-3
Vendored
+1
-3
@@ -393,9 +393,7 @@
|
||||
}
|
||||
|
||||
function isDebugBreak() {
|
||||
return process.execArgv.some((arg) => {
|
||||
return arg.match(/^--debug-brk(=[0-9]*)?$/);
|
||||
});
|
||||
return process.execArgv.some((arg) => /^--debug-brk(=[0-9]+)?$/.test(arg));
|
||||
}
|
||||
|
||||
function run(entryFunction) {
|
||||
|
||||
Reference in new issue
Block a user