/** * Extension of base driver method to default to user group instead of user id */ public function has_access($condition, $driver = null, $user = null) { if (is_null($user)) { $groups = $this->get_groups(); $user = reset($groups); } return parent::has_access($condition, $driver, $user); }