chore (fetcher): increase timeout to 15s #64
2 changed files with 4 additions and 4 deletions
|
|
@ -29,7 +29,7 @@ describe('fetch', () => {
|
||||||
'Referer': 'https://some-url.test',
|
'Referer': 'https://some-url.test',
|
||||||
},
|
},
|
||||||
responseType: 'text',
|
responseType: 'text',
|
||||||
timeout: 10000,
|
timeout: 15000,
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
@ -55,7 +55,7 @@ describe('fetch', () => {
|
||||||
'Referer': 'https://some-url.test',
|
'Referer': 'https://some-url.test',
|
||||||
},
|
},
|
||||||
responseType: 'text',
|
responseType: 'text',
|
||||||
timeout: 10000,
|
timeout: 15000,
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -70,7 +70,7 @@ describe('fetch', () => {
|
||||||
'Referer': 'https://some-url.test',
|
'Referer': 'https://some-url.test',
|
||||||
},
|
},
|
||||||
responseType: 'text',
|
responseType: 'text',
|
||||||
timeout: 10000,
|
timeout: 15000,
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@ export class Fetcher {
|
||||||
private readonly getConfig = (ctx: Context, url: URL, config?: AxiosRequestConfig): AxiosRequestConfig => {
|
private readonly getConfig = (ctx: Context, url: URL, config?: AxiosRequestConfig): AxiosRequestConfig => {
|
||||||
return {
|
return {
|
||||||
responseType: 'text',
|
responseType: 'text',
|
||||||
timeout: 10000,
|
timeout: 15000,
|
||||||
...config,
|
...config,
|
||||||
headers: {
|
headers: {
|
||||||
'User-Agent': this.createUserAgentForIp(ctx.ip),
|
'User-Agent': this.createUserAgentForIp(ctx.ip),
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue