You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: check npm.config before accessing its members
Sometimes, `npm.config` can be missing entirely, but there are several
places where `npm.config.foo` is accessed blindly, resulting in these
kinds of errors and stack traces:
TypeError: Cannot read property 'get' of undefined
at errorMessage (.../lib/utils/error-message.js:38:39)
...
TypeError: Cannot read property 'loaded' of undefined
at exit (.../lib/utils/error-handler.js:97:27)
...
LBYL by checking `npm.config` first. Addresses a small part of #502.
PR-URL: #508
Credit: @
Close: #508
Reviewed-by: @darcy Clarke
0 commit comments