Merge branch 'master' into feature--better-stack-trace
This commit is contained in:
commit
335cfd3c76
2 changed files with 3 additions and 3 deletions
|
@ -15,7 +15,7 @@ import {
|
||||||
import axiosRetry from 'axios-retry';
|
import axiosRetry from 'axios-retry';
|
||||||
import axiosBetterStacktrace from 'axios-better-stacktrace';
|
import axiosBetterStacktrace from 'axios-better-stacktrace';
|
||||||
|
|
||||||
const createAxiosInstance = (config: HttpModuleOptions) => {
|
const createAxiosRetry = (config?: HttpModuleOptions) => {
|
||||||
const axiosInstance = Axios.create(config);
|
const axiosInstance = Axios.create(config);
|
||||||
axiosRetry(axiosInstance, config);
|
axiosRetry(axiosInstance, config);
|
||||||
axiosBetterStacktrace(axiosInstance);
|
axiosBetterStacktrace(axiosInstance);
|
||||||
|
@ -27,7 +27,7 @@ const createAxiosInstance = (config: HttpModuleOptions) => {
|
||||||
HttpService,
|
HttpService,
|
||||||
{
|
{
|
||||||
provide: AXIOS_INSTANCE_TOKEN,
|
provide: AXIOS_INSTANCE_TOKEN,
|
||||||
useValue: Axios,
|
useValue: createAxiosRetry(),
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
exports: [HttpService],
|
exports: [HttpService],
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "nestjs-http-promise",
|
"name": "nestjs-http-promise",
|
||||||
"version": "1.1.0",
|
"version": "1.1.1",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"nestjs",
|
"nestjs",
|
||||||
"http",
|
"http",
|
||||||
|
|
Loading…
Reference in a new issue