Skip to content

Commit

Permalink
src,win: allow 403 errors for arm64 node.lib
Browse files Browse the repository at this point in the history
The servers hosting the header packages for Electron return 403
instead of 404 for the constructed URL for arm64 node.lib for
older releases that do not support arm64.

PR-URL: #1934
Reviewed-By: Rod Vagg <rod@vagg.org>
Reviewed-By: João Reis <reis@janeasystems.com>
  • Loading branch information
richardlau authored and rvagg committed Oct 24, 2019
1 parent c60c22d commit e6aca7d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ function install (fs, gyp, argv, callback) {

req.on('error', done)
req.on('response', function (res) {
if (res.statusCode === 404) {
if (res.statusCode === 403 || res.statusCode === 404) {
if (arch === 'arm64') {
// Arm64 is a newer platform on Windows and not all node distributions provide it.
log.verbose(`${name} was not found in ${libUrl}`)
Expand Down

0 comments on commit e6aca7d

Please sign in to comment.