From dcd27fd986427a8ccfbf0a9d01568cf7918b7659 Mon Sep 17 00:00:00 2001 From: Thomas Citharel Date: Thu, 10 Oct 2024 07:54:46 +0200 Subject: feat(http-client): expose default request timeout constant to be used instead of magic number 30 Will be used to set default where we are able to override the default timeout. See https://github.com/nextcloud/server/pull/48418 Signed-off-by: Thomas Citharel --- lib/private/Http/Client/Client.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/private/Http/Client/Client.php') diff --git a/lib/private/Http/Client/Client.php b/lib/private/Http/Client/Client.php index 62209ff9040..c3f8f589827 100644 --- a/lib/private/Http/Client/Client.php +++ b/lib/private/Http/Client/Client.php @@ -53,7 +53,7 @@ class Client implements IClient { $defaults = [ RequestOptions::VERIFY => $this->getCertBundle(), - RequestOptions::TIMEOUT => 30, + RequestOptions::TIMEOUT => IClient::DEFAULT_REQUEST_TIMEOUT, ]; $options['nextcloud']['allow_local_address'] = $this->isLocalAddressAllowed($options); -- cgit v1.2.3