X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FProtocol%2FFeed.php;h=203a2e83565d27396dcb4dc7486e17e8a5bab5a8;hb=9a76a14778198180c3a984291d968e3b059e67b1;hp=cc0915472d05cb75ee10aa849cb413abd003eab9;hpb=f04d40a37eb36e903433478d671a9dcd5bb6aacb;p=friendica.git diff --git a/src/Protocol/Feed.php b/src/Protocol/Feed.php index cc0915472d..203a2e8356 100644 --- a/src/Protocol/Feed.php +++ b/src/Protocol/Feed.php @@ -415,7 +415,7 @@ class Feed { $item["body"] .= "\n".$item['tag']; } // Add the link to the original feed entry if not present in feed - if (!strstr($item["body"], $item['plink']) && ($item['plink'] != '')) { + if (($item['plink'] != '') && !strstr($item["body"], $item['plink'])) { $item["body"] .= "[hr][url]".$item['plink']."[/url]"; } } @@ -423,7 +423,7 @@ class Feed { if (!$simulate) { logger("Stored feed: ".print_r($item, true), LOGGER_DEBUG); - $notify = item_is_remote_self($contact, $item); + $notify = Item::isRemoteSelf($contact, $item); // Distributed items should have a well formatted URI. // Additionally we have to avoid conflicts with identical URI between imported feeds and these items. @@ -433,7 +433,7 @@ class Feed { unset($item['parent-uri']); } - $id = item_store($item, false, $notify); + $id = Item::insert($item, false, $notify); logger("Feed for contact ".$contact["url"]." stored under id ".$id); } else {