Skip to content

Commit

Permalink
fix: use timespans from std instead of tokio
Browse files Browse the repository at this point in the history
  • Loading branch information
y5c4l3 committed Oct 22, 2023
1 parent 9433ad5 commit 5063b55
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/bancho.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@ use regex::Regex;
use tokio::net::TcpStream;
use tokio::sync::{broadcast, mpsc, oneshot};
use tokio::task::JoinHandle;
use tokio::time::{self, Duration, Instant};
use tokio::time;

use std::borrow::Borrow;
use std::collections::{HashMap, VecDeque};
use std::fmt;
use std::pin::Pin;
use std::str::FromStr;
use std::sync::Arc;
use std::time::{Duration, Instant};

use self::cache::UserCache;
use self::irc::Transport;
Expand Down Expand Up @@ -1294,7 +1295,9 @@ impl ClientActor {
.await?;
}
irc::Command::PONG(..) => {
timeout.reset(Instant::now() + self.options.pinger_timeout);
timeout.reset(
(Instant::now() + self.options.pinger_timeout).into()
);
}
irc::Command::PRIVMSG { target, body } => match prefix {
Some(prefix) => match prefix {
Expand Down

0 comments on commit 5063b55

Please sign in to comment.