X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning-block-sync%2Fsrc%2Frest.rs;h=3aff104d5546fe520407795d40e10307192a91ec;hb=2cb5b1af992263e219f47c1f09763ffd17fcda15;hp=3c2e76e23d7d5ee2eebd4a957185a34fef629583;hpb=89be6254aea425552bd97e0d0b07ed5932017ca0;p=rust-lightning diff --git a/lightning-block-sync/src/rest.rs b/lightning-block-sync/src/rest.rs index 3c2e76e2..3aff104d 100644 --- a/lightning-block-sync/src/rest.rs +++ b/lightning-block-sync/src/rest.rs @@ -24,7 +24,7 @@ impl RestClient { } /// Requests a resource encoded in `F` format and interpreted as type `T`. - async fn request_resource(&mut self, resource_path: &str) -> std::io::Result + pub async fn request_resource(&mut self, resource_path: &str) -> std::io::Result where F: TryFrom, Error = std::io::Error> + TryInto { let host = format!("{}:{}", self.endpoint.host(), self.endpoint.port()); let uri = format!("{}/{}", self.endpoint.path().trim_end_matches("/"), resource_path);