tools: update crypo check rule
This commit updates the custom crypto-check ESLint rule to detect require()
calls that come before all hasCrypto
checks.
Refs: https://github.com/nodejs/node/pull/25388
Note: This will fail CI until https://github.com/nodejs/node/pull/25388 lands.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
commit message follows commit guidelines