summaryrefslogtreecommitdiffstats
path: root/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php')
-rw-r--r--vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php b/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php
index 2b0d7e1c0..54b3c6ef9 100644
--- a/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php
+++ b/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php
@@ -99,7 +99,7 @@ class Curl extends Client
* Prepare HTTP headers
*
* @access private
- * @return array
+ * @return string[]
*/
private function prepareHeaders()
{
@@ -123,7 +123,7 @@ class Curl extends Client
* Prepare curl proxy context
*
* @access private
- * @return resource
+ * @return resource $ch
*/
private function prepareProxyContext($ch)
{
@@ -199,6 +199,9 @@ class Curl extends Client
$this->handleError($curl_errno);
}
+ // Update the url if there where redirects
+ $this->url = curl_getinfo($ch, CURLINFO_EFFECTIVE_URL);
+
curl_close($ch);
}
@@ -215,7 +218,7 @@ class Curl extends Client
list($status, $headers) = $this->parseHeaders(explode("\r\n", $this->headers[$this->headers_counter - 1]));
- // When resticted with open_basedir
+ // When restricted with open_basedir
if ($this->needToHandleRedirection($follow_location, $status)) {
return $this->handleRedirection($headers['Location']);
}