@@ 1,8 1,8 @@
use std::error::Error;
-use std::ops::Add;
+
use futures::stream::{SplitSink, SplitStream};
use futures::StreamExt;
-use log::{debug, error, info, Level, trace, warn};
+use log::{error, info, Level, trace, warn};
use wasm_bindgen::prelude::*;
use ws_stream_wasm::{WsErr, WsMessage, WsMeta, WsStream};
use starkingdoms_protocol::State;
@@ 13,7 13,7 @@ use futures::SinkExt;
use lazy_static::lazy_static;
use std::sync::Arc;
use std::sync::RwLock;
-use std::time::{Duration, SystemTime, UNIX_EPOCH};
+
use async_recursion::async_recursion;
use futures::FutureExt;
use wasm_bindgen_futures::JsFuture;
@@ 75,7 75,6 @@ lazy_static! {
pub const MAX_CONNECTION_TRIES: i32 = 10;
#[async_recursion(?Send)]
-#[allow(clippy::only_used_in_recursion)]
pub async fn main(gateway: &str, username: &str, backoff: i32) -> Result<(), Box<dyn Error>> {
info!("Backing off connection: waiting {} seconds", backoff * backoff);