config = $config; $this->request = $request; $this->phpbb_root_path = $phpbb_root_path; $this->phpEx = $phpEx; $this->cache = $cache; } /** * @inheritdoc */ public function get_data($row, $ignore_config = false) { return array( 'src' => '', 'width' => 0, 'height' => 0, ); } /** * @inheritdoc */ public function get_custom_html($row, $ignore_config = false) { return ''; } /** * @inheritdoc **/ public function prepare_form($template, $row, &$error, &$override_focus) { return false; } /** * @inheritdoc **/ public function process_form($template, $row, &$error) { return false; } /** * @inheritdoc **/ public function delete($row) { return true; } /** * @inheritdoc **/ public static function clean_row($row, $src = phpbb_avatar_driver_interface::FROM_USER) { $return = array(); $prefix = false; if ($src == phpbb_avatar_driver_interface::FROM_USER) { $prefix = 'user_'; } else if ($src == phpbb_avatar_driver_interface::FROM_GROUP) { $prefix = 'group_'; } if ($prefix) { $len = strlen($prefix); foreach ($row as $key => $val) { $sub = substr($key, 0, $len); if ($sub == $prefix) { $return[substr($key, $len)] = $val; } else { $return[$key] = $val; } } } else { $return = $row; } return $return; } }