Find removed ERR_INVALID_CALLBACK error code usage
ProprietaryThe ERR_INVALID_CALLBACK error code was removed in Node.js 18 (DEP0159). Invalid callbacks now throw ERR_INVALID_ARG_TYPE, which Node.js also throws for every other argument of the wrong type. Finds strings and regular expressions that name the old code, so checks against it can be updated by hand. Code that creates the error itself, such as a polyfill, may need to keep it.
org. openrewrite. node. migrate. find-err-invalid-callbackmod run . --recipe= org. openrewrite. node. migrate. find-err-invalid-callbackInstall it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.