Skip to content

Commit

Permalink
Add back the old module not found check
Browse files Browse the repository at this point in the history
So that we don't have to do a major version bump by dropping support for
older Node.js versions.
  • Loading branch information
TooTallNate committed Feb 27, 2019
1 parent ed7e626 commit f49851e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion bindings.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,9 @@ function bindings(opts) {
}
return b;
} catch (e) {
if (e.code !== 'MODULE_NOT_FOUND' && e.code !== 'QUALIFIED_PATH_RESOLUTION_FAILED') {
if (e.code !== 'MODULE_NOT_FOUND' &&
e.code !== 'QUALIFIED_PATH_RESOLUTION_FAILED' &&
!/not find/i.test(e.message)) {
throw e;
}
}
Expand Down

0 comments on commit f49851e

Please sign in to comment.