]> git.mxchange.org Git - friendica.git/commitdiff
Profile is now using the new function as well
authorMichael <heluecht@pirati.ca>
Sun, 10 Jun 2018 08:08:53 +0000 (08:08 +0000)
committerMichael <heluecht@pirati.ca>
Sun, 10 Jun 2018 08:08:53 +0000 (08:08 +0000)
mod/profile.php

index 2fb947a8365df885435447d14822f2c69e2dde79..91d04b2de9f8eeb4a2d013c20f0bf21b3edc6d76 100644 (file)
@@ -337,16 +337,9 @@ function profile_content(App $a, $update = 0)
                        $parents_arr[] = $rr['item_id'];
                }
 
-               $parents_str = implode(', ', $parents_arr);
-
-               $items = q(item_query($a->profile['profile_uid']) . " AND `item`.`uid` = %d
-                       AND `item`.`parent` IN (%s)
-                       $sql_extra ",
-                       intval($a->profile['profile_uid']),
-                       dbesc($parents_str)
-               );
-
-               $items = conv_sort($items, 'created');
+               $condition = ['uid' => $a->profile['profile_uid'], 'parent' => $parents_arr];
+               $result = Item::select($a->profile['profile_uid'], [], $condition);
+               $items = conv_sort(dba::inArray($result), 'created');
        } else {
                $items = [];
        }