Request URL:
https://howtogetgithubstars.com/api/newsletter
Request Method:
POST
Status Code:
405
Remote Address:
76.76.21.21:443
Referrer Policy:
strict-origin-when-cross-origin
And I got "Thank you, please check your email!"
And I got "Thank you, please check your email!"
I don't understand one thing, how come despite getting 405, I am getting success "Thank you, please check your email!" message? Are you not checking the status (error) code before showing the message?
{
"message": "Request failed with status code 405",
"name": "AxiosError",
"stack": "AxiosError: Request failed with status code 405\n at https://howtogetgithubstars.com/_next/static/chunks/356-dd9ab9f01a6d62a9.js:6:39972\n at XMLHttpRequest.f (https://howtogetgithubstars.com/_next/static/chunks/356-dd9ab9f01a6d62a9.js:6:40112)",
"config": {
"transitional": {
"silentJSONParsing": true,
"forcedJSONParsing": true,
"clarifyTimeoutError": false
},
"adapter": [
"xhr",
"http"
],
"transformRequest": [
null
],
"transformResponse": [
null
],
"timeout": 0,
"xsrfCookieName": "XSRF-TOKEN",
"xsrfHeaderName": "X-XSRF-TOKEN",
"maxContentLength": -1,
"maxBodyLength": -1,
"env": {},
"headers": {
"Accept": "application/json, text/plain, */*",
"Content-Type": "application/json"
},
"method": "post",
"url": "/api/newsletter",
"data": "{\"email\":\"test@pokemail.net\"}"
},
"code": "ERR_BAD_REQUEST",
"status": 405
}