ajnos
Member
Hi,
i'm trying to call a Method from a Controller in the Controller Helper.
_getCategoryModel is a valid method in my controller:
If i run this code, i'm getting:
i'm trying to call a Method from a Controller in the Controller Helper.
PHP:
public function assertCategoryValidAndViewable($categoryId, array $fetchOptions = array())
{
$fetchOptions += array('permissionCombinationId' => $this->_visitor['permission_combination_id']);
$category = $this->getCategoryOrError($categoryId, $fetchOptions);
if (isset($forum['node_permission_cache'])) {
$this->_visitor->setNodePermissions($category['node_id'], $category['node_permission_cache']);
unset($category['node_permission_cache']);
}
if (!$this->_controller->_getCategoryModel()->canView($category, $errorPhraseKey)) {
# throw $this->_controller->getErrorOrNoPermissionResponseException($errorPhraseKey);
}
return $category;
}
PHP:
/**
* @return Ragtek_AS_Model_Category
*/
protected function _getCategoryModel(){
return $this->getModelFromCache('Ragtek_AS_Model_Category');
}
Fatal error: Call to protected method Ragtek_AS_ControllerPublic_Abstract::_getCategoryModel() from context 'Ragtek_AS_ControllerHelper_AC' in C:\xampp\htdocs\xenforo\library\Ragtek\AS\ControllerHelper\AC.php on line 42