public function load_users_from_items($items, $component) { if (empty($items) || $component == 'none') { return; } $ids = array(); foreach ($items as $item) { $ids[] = $item->created_by; } if (!empty($ids)) { CJFunctions::load_users($component, $ids); } }
private function load_users($surveys) { if (empty($surveys)) { return; } $ids = array(); foreach ($surveys as $survey) { $ids[] = $survey->created_by; } if (!empty($ids)) { CJFunctions::load_users($this->params->get('user_avatar'), $ids); } }