feat: interpolation of proxy vars

This commit is contained in:
Anoop M D
2023-10-06 22:49:48 +05:30
parent 9474918853
commit de74edb50f
7 changed files with 164 additions and 23 deletions

View File

@@ -26,7 +26,9 @@ function makeAxiosInstance() {
if (error.response) {
const end = Date.now();
const start = error.config.headers['request-start-time'];
error.response.headers['request-duration'] = end - start;
if (error.response) {
error.response.headers['request-duration'] = end - start;
}
}
return Promise.reject(error);
}