async_client: Build the URL path a bit more cleanly.
parent
8583232873
commit
ee290add45
|
@ -564,10 +564,11 @@ impl AsyncClient {
|
||||||
{
|
{
|
||||||
let request: http::Request<Vec<u8>> = request.try_into()?;
|
let request: http::Request<Vec<u8>> = request.try_into()?;
|
||||||
let url = request.uri();
|
let url = request.uri();
|
||||||
let url = self
|
let path_and_query = url.path_and_query().unwrap();
|
||||||
.homeserver
|
let mut url = self.homeserver.clone();
|
||||||
.join(url.path_and_query().unwrap().as_str())
|
|
||||||
.unwrap();
|
url.set_path(path_and_query.path());
|
||||||
|
url.set_query(path_and_query.query());
|
||||||
|
|
||||||
trace!("Doing request {:?}", url);
|
trace!("Doing request {:?}", url);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue