Explorar o código

#1569 Error on homepage when not logged in

Alex Trofimov %!s(int64=8) %!d(string=hai) anos
pai
achega
a5186e4c5a
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      modules/base/groups/classes/BxBaseModGroupsModule.php

+ 1 - 1
modules/base/groups/classes/BxBaseModGroupsModule.php

@@ -477,7 +477,7 @@ class BxBaseModGroupsModule extends BxBaseModProfileModule
      */
     public function checkAllowedPost ($aDataEntry, $isPerformAction = false)
     {
-        if ($this->isFan($aDataEntry[$this->_oConfig->CNF['FIELD_ID']]) || ($aDataEntry[$this->_oConfig->CNF['FIELD_ID']] == BxDolProfile::getInstance()->getContentId() && BxDolProfile::getInstance()->getModule() == $this->getName()))
+        if (isLogged() && ($this->isFan($aDataEntry[$this->_oConfig->CNF['FIELD_ID']]) || ($aDataEntry[$this->_oConfig->CNF['FIELD_ID']] == BxDolProfile::getInstance()->getContentId() && BxDolProfile::getInstance()->getModule() == $this->getName())))
             return CHECK_ACTION_RESULT_ALLOWED;
 
         return _t('_sys_txt_access_denied');