Skip to content

Commit

Permalink
feat: fewer false positives for npm outages (#521)
Browse files Browse the repository at this point in the history
  • Loading branch information
mshanemc authored Sep 27, 2022
1 parent c76848f commit 0c465fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/commands/cli/install/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ class Npm extends Method.Base {
// I'm not confident that this is the best way to preempt any issues related to Npm's availability. Mainly
// because I couldn't find any documetation related to what status indicators might be used and when.
const response = await got.get(Npm.STATUS_URL).json<{ status: { indicator: string; description: string } }>();
return { service: 'Npm', available: response.status.indicator === 'none' };
return { service: 'Npm', available: ['none', 'minor'].includes(response.status.indicator) };
}

private async installAndTest(): Promise<Results> {
Expand Down

0 comments on commit 0c465fd

Please sign in to comment.