Merge pull request #33087 from nextcloud/fix/30282/external-storages

fix external storages access
pull/34756/head
John Molakvoæ 2 years ago committed by GitHub
commit 304c1b9b61
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -28,7 +28,6 @@ namespace OC\Http\Client;
use GuzzleHttp\Client as GuzzleClient;
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Handler\CurlHandler;
use OCP\Http\Client\IClient;
use OCP\Http\Client\IClientService;
use OCP\ICertificateManager;
@ -63,8 +62,7 @@ class ClientService implements IClientService {
* @return Client
*/
public function newClient(): IClient {
$handler = new CurlHandler();
$stack = HandlerStack::create($handler);
$stack = HandlerStack::create();
$stack->push($this->dnsPinMiddleware->addDnsPinning());
$client = new GuzzleClient(['handler' => $stack]);

@ -10,7 +10,6 @@ namespace Test\Http\Client;
use GuzzleHttp\Client as GuzzleClient;
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Handler\CurlHandler;
use OC\Http\Client\Client;
use OC\Http\Client\ClientService;
use OC\Http\Client\DnsPinMiddleware;
@ -42,8 +41,7 @@ class ClientServiceTest extends \Test\TestCase {
$localAddressChecker
);
$handler = new CurlHandler();
$stack = HandlerStack::create($handler);
$stack = HandlerStack::create();
$stack->push($dnsPinMiddleware->addDnsPinning());
$guzzleClient = new GuzzleClient(['handler' => $stack]);

Loading…
Cancel
Save