summaryrefslogtreecommitdiffstats
path: root/ipfs-api/src/client/internal.rs
diff options
context:
space:
mode:
Diffstat (limited to 'ipfs-api/src/client/internal.rs')
-rw-r--r--ipfs-api/src/client/internal.rs11
1 files changed, 7 insertions, 4 deletions
diff --git a/ipfs-api/src/client/internal.rs b/ipfs-api/src/client/internal.rs
index 5667ab2..fcc4ddb 100644
--- a/ipfs-api/src/client/internal.rs
+++ b/ipfs-api/src/client/internal.rs
@@ -79,7 +79,7 @@ impl Default for IpfsClient {
///
fn default() -> IpfsClient {
Self::from_ipfs_config()
- .unwrap_or_else(|| Self::from_host_and_port("localhost", 5001).unwrap())
+ .unwrap_or_else(|| Self::from_host_and_port(Scheme::HTTP, "localhost", 5001).unwrap())
}
}
@@ -88,7 +88,7 @@ impl IpfsClient {
///
#[deprecated(
since = "0.7.2",
- note = "Please use [`client::TryFromUri::from_host_and_port`]"
+ note = "Please use [`client::TryFromUri::from_host_and_port`]. Removing in next major version."
)]
pub fn new(host: &str, port: u16) -> Result<IpfsClient, InvalidUri> {
let uri = format!("http://{}:{}", host, port);
@@ -97,14 +97,17 @@ impl IpfsClient {
Self::from_str(&uri[..])
}
- #[deprecated(since = "0.7.2", note = "Please use [`client::TryFromUri::from_uri`]")]
+ #[deprecated(
+ since = "0.7.2",
+ note = "Please use [`client::TryFromUri::from_uri`]. Removing in next major version."
+ )]
pub fn new_from_uri(uri: &str) -> Result<IpfsClient, InvalidUri> {
Self::from_str(uri)
}
#[deprecated(
since = "0.7.2",
- note = "Please use [`client::TryFromUri::from_socket`]"
+ note = "Please use [`client::TryFromUri::from_socket`]. Removing in next major version."
)]
pub fn from(socket_addr: SocketAddr) -> IpfsClient {
Self::from_socket(Scheme::HTTP, socket_addr).unwrap()