mirror of
https://github.com/tenrok/axios.git
synced 2026-06-05 16:42:32 +03:00
Adding HTTP status code for transformResponse (#4580)
* Adding HTTP status code for transformResponse * refs #1214 * Fix wrong argument for tranformResponse * Fix test wrong argument for tranformData * Add test case for transformData * Add test case for transformData (reference headers case) Co-authored-by: Jay <jasonsaayman@gmail.com>
This commit is contained in:
@@ -36,6 +36,7 @@ module.exports = function dispatchRequest(config) {
|
||||
config,
|
||||
config.data,
|
||||
config.headers,
|
||||
null,
|
||||
config.transformRequest
|
||||
);
|
||||
|
||||
@@ -63,6 +64,7 @@ module.exports = function dispatchRequest(config) {
|
||||
config,
|
||||
response.data,
|
||||
response.headers,
|
||||
response.status,
|
||||
config.transformResponse
|
||||
);
|
||||
|
||||
@@ -77,6 +79,7 @@ module.exports = function dispatchRequest(config) {
|
||||
config,
|
||||
reason.response.data,
|
||||
reason.response.headers,
|
||||
reason.response.status,
|
||||
config.transformResponse
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user