Skip to content

Commit

Permalink
chore: Replace instant with web-time crate
Browse files Browse the repository at this point in the history
  • Loading branch information
oblique committed Aug 12, 2024
1 parent b3cdb66 commit 8fc4d58
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
5 changes: 1 addition & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ fnv = "1.0.5"
futures-core = "0.3"
futures-timer = "3"
futures-util = "0.3"
instant = "0.1.12"
web-time = "1.1.0"
libp2p-core = "0.42"
libp2p-identity = "0.2"
libp2p-swarm = "0.45"
Expand Down Expand Up @@ -68,7 +68,7 @@ tracing-subscriber = { version = "0.3.17", features = ["env-filter"] }
log = "0.4.18"

[features]
wasm-bindgen = ["futures-timer/wasm-bindgen", "instant/wasm-bindgen"]
wasm-bindgen = ["futures-timer/wasm-bindgen"]

[package.metadata.docs.rs]
rustdoc-args = ["--cfg", "docsrs"]
2 changes: 1 addition & 1 deletion src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ use futures_timer::Delay;
use futures_util::future::{AbortHandle, Abortable, FutureExt};
use futures_util::sink::SinkExt;
use futures_util::stream::{FuturesUnordered, StreamExt};
use instant::Instant;
use libp2p_core::upgrade::ReadyUpgrade;
use libp2p_identity::PeerId;
use libp2p_swarm::{
ConnectionHandlerEvent, ConnectionId, NotifyHandler, StreamProtocol, SubstreamProtocol, ToSwarm,
};
use smallvec::SmallVec;
use tracing::debug;
use web_time::Instant;

use crate::incoming_stream::ClientMessage;
use crate::message::Codec;
Expand Down

0 comments on commit 8fc4d58

Please sign in to comment.