Fix return type for broken feeds (#3423)

Fix a rare error when an invalid feed is forced to be added again.
FreshRSS code (not upstream)
pull/3426/head
Alexandre Alapetite 4 years ago committed by GitHub
parent d42b4c299c
commit 23c43b1fbf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      lib/SimplePie/SimplePie.php

@ -1424,7 +1424,7 @@ class SimplePie
// Fetch the data via SimplePie_File into $this->raw_data // Fetch the data via SimplePie_File into $this->raw_data
if (($fetched = $this->fetch_data($cache)) === true) if (($fetched = $this->fetch_data($cache)) === true)
{ {
return $this->data['mtime']; return empty($this->data['mtime']) ? false : $this->data['mtime'];
} }
elseif ($fetched === false) { elseif ($fetched === false) {
return false; return false;

Loading…
Cancel
Save