fn build_url()

in client/src/client.rs [284:300]


    fn build_url(
        &self,
        host: &str,
        path: &str,
        query_params: &Option<Vec<(String, String)>>,
    ) -> Result<url::Url, ConfigError> {
        let result = match query_params {
            Some(query_params) if query_params.is_empty() => {
                url::Url::parse(&format!("{}{}", host, path))
            }
            None => url::Url::parse(&format!("{}{}", host, path)),
            Some(query_params) => {
                url::Url::parse_with_params(&format!("{}{}", host, path), query_params)
            }
        };
        Ok(result?)
    }