mirror of
https://github.com/warengroup/eximiabots-radiox.git
synced 2024-12-23 06:33:18 +00:00
7 lines
218 B
JavaScript
7 lines
218 B
JavaScript
module.exports = function (response) {
|
|
if (response.ok) { // res.status >= 200 && res.status < 300
|
|
return response;
|
|
} else {
|
|
throw new Error(response.status + " " + response.statusText);
|
|
}
|
|
} |