diff options
author | Chocobozzz <me@florianbigard.com> | 2021-10-13 09:57:20 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-10-13 09:57:20 +0200 |
commit | e81f6ccf989d4573b59ec7b2bf2812fe3e9fb534 (patch) | |
tree | 7076c8de60a95f88692c90b23f531df61215197e /server | |
parent | ac0725aa88bcd17446d80ead3246ad9947d12b14 (diff) | |
download | PeerTube-e81f6ccf989d4573b59ec7b2bf2812fe3e9fb534.tar.gz PeerTube-e81f6ccf989d4573b59ec7b2bf2812fe3e9fb534.tar.zst PeerTube-e81f6ccf989d4573b59ec7b2bf2812fe3e9fb534.zip |
Fix requests timeout
Diffstat (limited to 'server')
-rw-r--r-- | server/helpers/requests.ts | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/server/helpers/requests.ts b/server/helpers/requests.ts index 535478017..74ed1d786 100644 --- a/server/helpers/requests.ts +++ b/server/helpers/requests.ts | |||
@@ -96,10 +96,6 @@ const peertubeGot = got.extend({ | |||
96 | path | 96 | path |
97 | }, httpSignatureOptions) | 97 | }, httpSignatureOptions) |
98 | } | 98 | } |
99 | }, | ||
100 | |||
101 | (options: GotOptions) => { | ||
102 | options.timeout = REQUEST_TIMEOUT | ||
103 | } | 99 | } |
104 | ] | 100 | ] |
105 | } | 101 | } |
@@ -213,6 +209,7 @@ function buildGotOptions (options: PeerTubeRequestOptions) { | |||
213 | return { | 209 | return { |
214 | method: options.method, | 210 | method: options.method, |
215 | dnsCache: true, | 211 | dnsCache: true, |
212 | timeout: REQUEST_TIMEOUT, | ||
216 | json: options.json, | 213 | json: options.json, |
217 | searchParams: options.searchParams, | 214 | searchParams: options.searchParams, |
218 | headers, | 215 | headers, |