Browse Source

Minor - Format code

Julio Montoya 5 years ago
parent
commit
f8d5880b1e
1 changed files with 8 additions and 9 deletions
  1. 8 9
      main/inc/ajax/social.ajax.php

+ 8 - 9
main/inc/ajax/social.ajax.php

@@ -219,19 +219,12 @@ switch ($action) {
             $comment = isset($_REQUEST['comment']) ? $_REQUEST['comment'] : '';
             if (!empty($comment)) {
                 $messageId = SocialManager::sendWallMessage(
-                    api_get_user_id(),
+                    $userId,
                     $messageInfo['user_receiver_id'],
                     $comment,
                     $messageId,
                     MESSAGE_STATUS_WALL
                 );
-                /*if ($messageId && !empty($_FILES['picture']['tmp_name'])) {
-                    self::sendWallMessageAttachmentFile(
-                        $friendId,
-                        $_FILES['picture'],
-                        $messageId
-                    );
-                }*/
                 if ($messageId) {
                     $messageInfo = MessageManager::get_message_by_id($messageId);
                     echo SocialManager::processPostComment($messageInfo);
@@ -273,6 +266,7 @@ switch ($action) {
         $start = isset($_REQUEST['start']) ? (int) $_REQUEST['start'] : 0;
         $length = isset($_REQUEST['length']) ? (int) $_REQUEST['length'] : 10;
         $userId = isset($_REQUEST['u']) ? (int) $_REQUEST['u'] : api_get_user_id();
+
         $html = '';
         if ($userId == api_get_user_id()) {
             $threadList = SocialManager::getThreadList($userId);
@@ -281,7 +275,12 @@ switch ($action) {
                 $threadIdList = array_column($threadList, 'id');
             }
 
-            $html = SocialManager::getMyWallMessages($userId, $start, SocialManager::DEFAULT_SCROLL_NEW_POST, $threadIdList);
+            $html = SocialManager::getMyWallMessages(
+                $userId,
+                $start,
+                SocialManager::DEFAULT_SCROLL_NEW_POST,
+                $threadIdList
+            );
             $html = $html['posts'];
         } else {
             $messages = SocialManager::getWallMessages(