summaryrefslogtreecommitdiff
path: root/classes/api.php
diff options
context:
space:
mode:
authorShemi <[email protected]>2022-09-29 11:18:41 +0300
committerShemi <[email protected]>2022-09-29 11:18:41 +0300
commitf0a20a62c7f43411ebf12a89743c8378b29ee5f8 (patch)
tree872998480d238e9a76d088bc25c28c46a914a95d /classes/api.php
parente2f9a3b9a487ac6307e27048b84c120622d369d0 (diff)
parent051fc29b551d6426e53f440c70c3fd645aedc97f (diff)
Merge branch 'master' into master
Diffstat (limited to 'classes/api.php')
-rwxr-xr-xclasses/api.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/classes/api.php b/classes/api.php
index 12b47e209..2416dd7c9 100755
--- a/classes/api.php
+++ b/classes/api.php
@@ -333,7 +333,7 @@ class API extends Handler {
'published' => self::_param_to_bool($entry->published),
'comments' => $entry->comments,
'author' => $entry->author,
- 'updated' => (int) strtotime($entry->updated),
+ 'updated' => (int) strtotime($entry->updated ?? ''),
'feed_id' => $entry->feed_id,
'attachments' => Article::_get_enclosures($entry->id),
'score' => (int) $entry->score,
@@ -640,7 +640,7 @@ class API extends Handler {
'unread' => (int) $unread,
'has_icon' => $has_icon,
'cat_id' => (int) $feed->cat_id,
- 'last_updated' => (int) strtotime($feed->last_updated),
+ 'last_updated' => (int) strtotime($feed->last_updated ?? ''),
'order_id' => (int) $feed->order_id,
];
@@ -670,7 +670,7 @@ class API extends Handler {
->find_one($feed_id);
if ($feed) {
- $last_updated = strtotime($feed->last_updated);
+ $last_updated = strtotime($feed->last_updated ?? '');
$cache_images = self::_param_to_bool($feed->cache_images);
if (!$cache_images && time() - $last_updated > 120) {
@@ -787,7 +787,7 @@ class API extends Handler {
"unread" => self::_param_to_bool($line["unread"]),
"marked" => self::_param_to_bool($line["marked"]),
"published" => self::_param_to_bool($line["published"]),
- "updated" => (int)strtotime($line["updated"]),
+ "updated" => (int)strtotime($line["updated"] ?? ''),
"is_updated" => $is_updated,
"title" => $line["title"],
"link" => $line["link"],