Skip to content

Commit

Permalink
Merge pull request #322 from snyk-tech-services/feat/no-retries-on-504
Browse files Browse the repository at this point in the history
feat: skip retrying 504s - Timed out waiting for response
  • Loading branch information
lili2311 authored Apr 22, 2022
2 parents 6415cac + adb434e commit aeb23cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/api/import/request-with-rate-limit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export async function requestWithRateLimitHandling(
);
break;
}
if (e.data.code === 404) {
if ([404, 504].includes(e.data.code)) {
break;
}
attempt += 1;
Expand Down

0 comments on commit aeb23cd

Please sign in to comment.