Skip to content

Extend retry statusCode in order to work for 404. #1813

Answered by sindresorhus
y0x asked this question in Q&A
Discussion options

You must be logged in to vote

//retry: { statusCode: got.defaults.options.retry.statusCode.push(404) }, //does not work | not clean

retry: { statusCodes: [...got.defaults.options.retry.statusCodes, 404] },

Replies: 3 comments 3 replies

Comment options

You must be logged in to vote
2 replies
@y0x
Comment options

@titanism
Comment options

Answer selected by szmarczak
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@szmarczak
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants
Converted from issue

This discussion was converted from issue #1812 on July 29, 2021 12:37.