]> git.mxchange.org Git - friendica.git/blobdiff - include/conversation.php
Merge pull request #8163 from MrPetovan/task/7817-custom-fields-part-3
[friendica.git] / include / conversation.php
index e09f163efd19d3fa0588e37a665d16c886e78595..a5884847662d9b8ac2a6aa5310d4a7240a882f09 100644 (file)
@@ -8,7 +8,6 @@ use Friendica\Content\ContactSelector;
 use Friendica\Content\Feature;
 use Friendica\Content\Pager;
 use Friendica\Content\Text\BBCode;
-use Friendica\Core\Config;
 use Friendica\Core\Hook;
 use Friendica\Core\Logger;
 use Friendica\Core\Protocol;
@@ -495,7 +494,7 @@ function conversation(App $a, array $items, Pager $pager, $mode, $update, $previ
                }
        } elseif ($mode === 'profile') {
                $items = conversation_add_children($items, false, $order, $uid);
-               $profile_owner = $a->profile['profile_uid'];
+               $profile_owner = $a->profile['uid'];
 
                if (!$update) {
                        $tab = 'posts';
@@ -509,7 +508,7 @@ function conversation(App $a, array $items, Pager $pager, $mode, $update, $previ
                                 */
 
                                $live_update_div = '<div id="live-profile"></div>' . "\r\n"
-                                       . "<script> var profile_uid = " . $a->profile['profile_uid']
+                                       . "<script> var profile_uid = " . $a->profile['uid']
                                        . "; var netargs = '?f='; var profile_page = " . $pager->getPage() . "; </script>\r\n";
                        }
                }
@@ -792,7 +791,7 @@ function conversation(App $a, array $items, Pager $pager, $mode, $update, $previ
 /**
  * Fetch all comments from a query. Additionally set the newest resharer as thread owner.
  *
- * @param array   $thread_items Database statement with thread posts
+ * @param mixed   $thread_items Database statement with thread posts
  * @param boolean $pinned       Is the item pinned?
  *
  * @return array items with parents and comments
@@ -850,7 +849,7 @@ function conversation_fetch_comments($thread_items, $pinned) {
  * @throws \Friendica\Network\HTTPException\InternalServerErrorException
  */
 function conversation_add_children(array $parents, $block_authors, $order, $uid) {
-       $max_comments = Config::get('system', 'max_comments', 100);
+       $max_comments = DI::config()->get('system', 'max_comments', 100);
 
        $params = ['order' => ['uid', 'commented' => true]];
 
@@ -920,9 +919,9 @@ function item_photo_menu($item) {
        }
 
        if ($sparkle) {
-               $status_link = $profile_link . '?tab=status';
+               $status_link = $profile_link . '/status';
                $photos_link = str_replace('/profile/', '/photos/', $profile_link);
-               $profile_link = $profile_link . '?=profile';
+               $profile_link = $profile_link . '/profile';
        }
 
        if (!empty($pcid)) {
@@ -1215,6 +1214,7 @@ function status_editor(App $a, $x, $notes_cid = 0, $popup = false)
                '$return_path'  => $query_str,
                '$action'       => 'item',
                '$share'        => ($x['button'] ?? '') ?: DI::l10n()->t('Share'),
+               '$loading'      => DI::l10n()->t('Loading...'),
                '$upload'       => DI::l10n()->t('Upload photo'),
                '$shortupload'  => DI::l10n()->t('upload photo'),
                '$attach'       => DI::l10n()->t('Attach file'),