]> git.mxchange.org Git - friendica.git/commitdiff
Oh no ... there are still some notices that want to be removed ...
authorMichael <heluecht@pirati.ca>
Fri, 24 Aug 2018 11:09:58 +0000 (11:09 +0000)
committerMichael <heluecht@pirati.ca>
Fri, 24 Aug 2018 11:09:58 +0000 (11:09 +0000)
include/items.php
mod/photos.php
src/Network/Probe.php

index 08858682e60cefc5844370e0d408f987782a504b..2d7597dcd68c6666a090fad3cc67607cd308421e 100644 (file)
@@ -29,6 +29,10 @@ function add_page_info_data(array $data, $no_photos = false)
 {
        Addon::callHooks('page_info_data', $data);
 
+       if (empty($data['type'])) {
+               return '';
+       }
+
        // It maybe is a rich content, but if it does have everything that a link has,
        // then treat it that way
        if (($data["type"] == "rich") && is_string($data["title"]) &&
index e246c98c3d84ccf2712c5acd621a476c908fb34b..b26c5edb9b3ce4ad42ad4df7f7fe833b5d677ef1 100644 (file)
@@ -1376,7 +1376,7 @@ function photos_content(App $a)
                        $a->set_pager_total(DBA::count('item', $condition));
 
                        $params = ['order' => ['id'], 'limit' => [$a->pager['start'], $a->pager['itemspage']]];
-                       $result = Item::selectForUser($link_item['uid'], [], $condition, $params);
+                       $result = Item::selectForUser($link_item['uid'], Item::ITEM_FIELDLIST, $condition, $params);
                        $items = Item::inArray($result);
 
                        if (local_user() && (local_user() == $link_item['uid'])) {
@@ -1551,7 +1551,7 @@ function photos_content(App $a)
                                        $body_e = BBCode::convert($item['body']);
 
                                        $comments .= replace_macros($template,[
-                                               '$id' => $item['item_id'],
+                                               '$id' => $item['id'],
                                                '$profile_url' => $profile_url,
                                                '$name' => $item['author-name'],
                                                '$thumb' => $item['author-avatar'],
index 5bbdf7c4e03f675347c1d0a442eea7573e62443e..258bb6c628cd3271b45f54fc6eb6d8656217e870 100644 (file)
@@ -934,11 +934,12 @@ class Probe
 
                $prof_data = [];
 
-               // The "addr" is not always part of the fetched data
-               if (!empty($data["addr"])) {
-                       $prof_data["addr"] = $data["addr"];
+               if (empty($data["addr"])) {
+                       $probe_data = self::uri($profile_link);
+                       $data["addr"] = $probe_data["addr"];
                }
 
+               $prof_data["addr"]         = $data["addr"];
                $prof_data["nick"]         = $data["nick"];
                $prof_data["dfrn-request"] = $data["request"];
                $prof_data["dfrn-confirm"] = $data["confirm"];