Просмотр исходного кода

#4558- Build-in API support (fix email view)

romanlesnikov 2 лет назад
Родитель
Сommit
18d7b62115
1 измененных файлов с 10 добавлено и 4 удалено
  1. 10 4
      template/scripts/BxBasePage.php

+ 10 - 4
template/scripts/BxBasePage.php

@@ -564,11 +564,17 @@ class BxBasePage extends BxDolPage
                  * Process page cover with related menus and lists.
                  */
                 if(BxDolCover::getInstance($this)->isCover()) {
+                    $aProfileInfo = BxDolProfile::getData($this->_aProfileInfo['id'], [
+                        'get_avatar' => 'getAvatarBig',
+                        'with_info' => true
+                    ]);
+                    
+                    unset($aProfileInfo['info']['profile_email']);
+                    unset($aProfileInfo['info']['profile_last_active']);
+                    unset($aProfileInfo['info']['profile_ip']);
+                    
                     $a['cover_block'] = [
-                        'profile' => BxDolProfile::getData($this->_aProfileInfo['id'], [
-                            'get_avatar' => 'getAvatarBig',
-                            'with_info' => true
-                        ]),
+                        'profile' => $aProfileInfo,
                         'actions_menu' => '',
                         'meta_menu' => '',
                         'badges' => BxDolProfile::getInstance($this->_aProfileInfo['id'])->getBadges(),