[v6.x backport] cluster, dns, repl, tls, util: fix RegExp nits by vsemozhetbyt · Pull Request #14348 · nodejs/node

@nodejs-github-bot added lib / src

Issues and PRs related to general changes in the lib or src directory.

v6.x labels

Jul 18, 2017

@vsemozhetbyt

* Take RegExp creation out of cycles.
* Use test(), not match() in boolean context.
* Remove redundant RegExp parts.

PR-URL: #13536
Reviewed-By: Anna Henningsen <anna@addaleax.net>

addaleax

MylesBorins pushed a commit that referenced this pull request

Jul 18, 2017
* Take RegExp creation out of cycles.
* Use test(), not match() in boolean context.
* Remove redundant RegExp parts.

Backport-PR-URL: #14348
PR-URL: #13536
Reviewed-By: Anna Henningsen <anna@addaleax.net>

MylesBorins pushed a commit that referenced this pull request

Jul 21, 2017
* Take RegExp creation out of cycles.
* Use test(), not match() in boolean context.
* Remove redundant RegExp parts.

Backport-PR-URL: #14348
PR-URL: #13536
Reviewed-By: Anna Henningsen <anna@addaleax.net>