From 39e8fb2036945303836c461a61f133b0059c8991 Mon Sep 17 00:00:00 2001 From: Christian Cleberg Date: Mon, 22 May 2023 15:19:08 -0500 Subject: initial commit --- .../guzzlehttp/guzzle/src/Handler/CurlHandler.php | 45 ++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php (limited to 'vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php') diff --git a/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php b/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php new file mode 100644 index 0000000..43577da --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php @@ -0,0 +1,45 @@ +factory = isset($options['handle_factory']) + ? $options['handle_factory'] + : new CurlFactory(3); + } + + public function __invoke(RequestInterface $request, array $options) + { + if (isset($options['delay'])) { + usleep($options['delay'] * 1000); + } + + $easy = $this->factory->create($request, $options); + curl_exec($easy->handle); + $easy->errno = curl_errno($easy->handle); + + return CurlFactory::finish($this, $easy, $this->factory); + } +} -- cgit v1.2.3-70-g09d2