protected function prepareRow($row) { // State if (!$row->id) { $row->state = 1; } // Associations if (JLanguageAssociations::isEnabled()) { $row->associations = array(); if ($row->id) { require_once JPATH_SITE . '/components/com_k2/helpers/association.php'; $associations = K2HelperAssociation::getCategoryAssociations($row->id); foreach ($associations as $tag => $association) { $row->associations[$tag] = $association; } } } }