making sure $params['group'] is actually an int group_id