We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6f014d0 commit 25ac669Copy full SHA for 25ac669
doc/api/http.md
@@ -2233,6 +2233,8 @@ http.get('http://nodejs.org/dist/index.json', (res) => {
2233
const contentType = res.headers['content-type'];
2234
2235
let error;
2236
+ // Any 2xx status code signals a successful response but
2237
+ // here we're only checking for 200.
2238
if (statusCode !== 200) {
2239
error = new Error('Request Failed.\n' +
2240
`Status Code: ${statusCode}`);
0 commit comments