Merge pull request #184 from woocommerce/PCP-173-5-seconds-timeout-error-in-live

Add 30 seconds timeout by default to all requests
This commit is contained in:
Emili Castells 2021-06-23 10:48:47 +02:00 committed by GitHub
commit eb8620aa7b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -24,6 +24,8 @@ trait RequestTrait {
*/
private function request( string $url, array $args ) {
$args['timeout'] = 30;
/**
* This filter can be used to alter the request args.
* For example, during testing, the PayPal-Mock-Response header could be