diff --git a/composer.json b/composer.json index b1228c7..1afcf09 100644 --- a/composer.json +++ b/composer.json @@ -17,7 +17,7 @@ "fguillot/simple-validator": "v1.0.0", "fguillot/json-rpc": "v1.2.3", "fguillot/picodb": "v1.0.14 ", - "fguillot/picofeed": "v0.1.32", + "fguillot/picofeed": "v0.1.33", "pda/pheanstalk": "v3.1.0", "ircmaxell/password-compat": "^1.0.4" }, diff --git a/composer.lock b/composer.lock index 9cb9ee5..1017d95 100644 --- a/composer.lock +++ b/composer.lock @@ -4,8 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "adf4db185f22a2e00d21d278ba1fa7bc", - "content-hash": "98e20f0db34bd3ce534c09d7bfcf0179", + "hash": "2e41ff910022a7ea02922ced8ec2e1be", + "content-hash": "13b249b65e7dc65f4c7de72a80ee31c3", "packages": [ { "name": "fguillot/json-rpc", @@ -88,16 +88,16 @@ }, { "name": "fguillot/picofeed", - "version": "v0.1.32", + "version": "v0.1.33", "source": { "type": "git", "url": "https://github.com/fguillot/picoFeed.git", - "reference": "fb20400dc8400474bf50d40976fa48beb018166b" + "reference": "b44f1e1fdecfd2e7f158df86a23e1ea3dfb4e16f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/fguillot/picoFeed/zipball/fb20400dc8400474bf50d40976fa48beb018166b", - "reference": "fb20400dc8400474bf50d40976fa48beb018166b", + "url": "https://api.github.com/repos/fguillot/picoFeed/zipball/b44f1e1fdecfd2e7f158df86a23e1ea3dfb4e16f", + "reference": "b44f1e1fdecfd2e7f158df86a23e1ea3dfb4e16f", "shasum": "" }, "require": { @@ -137,7 +137,7 @@ ], "description": "Modern library to handle RSS/Atom feeds", "homepage": "https://github.com/fguillot/picoFeed", - "time": "2017-04-05 19:55:52" + "time": "2017-04-07 01:57:15" }, { "name": "fguillot/simple-validator", diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 828e122..5f7c9b7 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -265,17 +265,17 @@ }, { "name": "fguillot/picofeed", - "version": "v0.1.32", - "version_normalized": "0.1.32.0", + "version": "v0.1.33", + "version_normalized": "0.1.33.0", "source": { "type": "git", "url": "https://github.com/fguillot/picoFeed.git", - "reference": "fb20400dc8400474bf50d40976fa48beb018166b" + "reference": "b44f1e1fdecfd2e7f158df86a23e1ea3dfb4e16f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/fguillot/picoFeed/zipball/fb20400dc8400474bf50d40976fa48beb018166b", - "reference": "fb20400dc8400474bf50d40976fa48beb018166b", + "url": "https://api.github.com/repos/fguillot/picoFeed/zipball/b44f1e1fdecfd2e7f158df86a23e1ea3dfb4e16f", + "reference": "b44f1e1fdecfd2e7f158df86a23e1ea3dfb4e16f", "shasum": "" }, "require": { @@ -295,7 +295,7 @@ "suggest": { "ext-curl": "PicoFeed will use cURL if present" }, - "time": "2017-04-05 19:55:52", + "time": "2017-04-07 01:57:15", "bin": [ "picofeed" ], diff --git a/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php b/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php index 634b01e..f4a6578 100644 --- a/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php +++ b/vendor/fguillot/picofeed/lib/PicoFeed/Client/Curl.php @@ -299,7 +299,11 @@ class Curl extends Client list($status, $headers) = HttpHeaders::parse(explode("\n", $this->response_headers[$this->response_headers_count - 1])); if ($this->isRedirection($status)) { - return $this->handleRedirection($headers['Location']); + if (empty($headers['Location'])) { + $status = 200; + } else { + return $this->handleRedirection($headers['Location']); + } } return array( diff --git a/vendor/fguillot/picofeed/lib/PicoFeed/Client/HttpHeaders.php b/vendor/fguillot/picofeed/lib/PicoFeed/Client/HttpHeaders.php index 5ddcafc..34b8139 100644 --- a/vendor/fguillot/picofeed/lib/PicoFeed/Client/HttpHeaders.php +++ b/vendor/fguillot/picofeed/lib/PicoFeed/Client/HttpHeaders.php @@ -24,7 +24,7 @@ class HttpHeaders implements ArrayAccess public function offsetGet($offset) { - return $this->headers[strtolower($offset)]; + return $this->offsetExists($offset) ? $this->headers[strtolower($offset)] : ''; } public function offsetSet($offset, $value) diff --git a/vendor/fguillot/picofeed/lib/PicoFeed/Reader/Reader.php b/vendor/fguillot/picofeed/lib/PicoFeed/Reader/Reader.php index 7b26dea..769ffe9 100644 --- a/vendor/fguillot/picofeed/lib/PicoFeed/Reader/Reader.php +++ b/vendor/fguillot/picofeed/lib/PicoFeed/Reader/Reader.php @@ -56,13 +56,13 @@ class Reader extends Base /** * Discover and download a feed. * - * @param string $url Feed or website url + * @param string $url Feed or website url * @param string $last_modified Last modified HTTP header - * @param string $etag Etag HTTP header - * @param string $username HTTP basic auth username - * @param string $password HTTP basic auth password - * - * @return \PicoFeed\Client\Client + * @param string $etag Etag HTTP header + * @param string $username HTTP basic auth username + * @param string $password HTTP basic auth password + * @return Client + * @throws SubscriptionNotFoundException */ public function discover($url, $last_modified = '', $etag = '', $username = '', $password = '') {