]> git.mxchange.org Git - friendica.git/commitdiff
Issue 11393: Fix failing preview
authorMichael <heluecht@pirati.ca>
Wed, 6 Apr 2022 16:26:51 +0000 (16:26 +0000)
committerMichael <heluecht@pirati.ca>
Wed, 6 Apr 2022 16:26:51 +0000 (16:26 +0000)
src/Model/Item.php

index bf56a72424599dab8b09e75c5a38055c13703d6e..d040c876de6df1ab4a1ee614102173943bfbc66a 100644 (file)
@@ -3191,9 +3191,9 @@ class Item
         */
        public static function getPlink($item)
        {
-               if (Network::isValidHttpUrl($item['plink'])) {
+               if (!empty($item['plink']) && Network::isValidHttpUrl($item['plink'])) {
                        $plink = $item['plink'];
-               } elseif (Network::isValidHttpUrl($item['uri']) && !Network::isLocalLink($item['uri'])) {
+               } elseif (!empty($item['uri']) && Network::isValidHttpUrl($item['uri']) && !Network::isLocalLink($item['uri'])) {
                        $plink = $item['uri'];
                }