diff --git a/src/use_websocket.rs b/src/use_websocket.rs index bb348c9..1a3c0d5 100644 --- a/src/use_websocket.rs +++ b/src/use_websocket.rs @@ -239,8 +239,8 @@ where Tx: Send + Sync + 'static, Rx: Send + Sync + 'static, C: Encoder + Decoder, - C: HybridEncoder>::Encoded, Error=>::Error>, - C: HybridDecoder>::Encoded, Error=>::Error>, + C: HybridEncoder>::Encoded, Error = >::Error>, + C: HybridDecoder>::Encoded, Error = >::Error>, { use_websocket_with_options::(url, UseWebSocketOptions::default()) } @@ -265,8 +265,8 @@ where Tx: Send + Sync + 'static, Rx: Send + Sync + 'static, C: Encoder + Decoder, - C: HybridEncoder>::Encoded, Error=>::Error>, - C: HybridDecoder>::Encoded, Error=>::Error>, + C: HybridEncoder>::Encoded, Error = >::Error>, + C: HybridDecoder>::Encoded, Error = >::Error>, { let url = normalize_url(url); @@ -309,8 +309,8 @@ where if !manually_closed_ref.get_value() && !reconnect_limit.is_exceeded_by(reconnect_times_ref.get_value()) && ws_ref - .get_value() - .map_or(false, |ws: WebSocket| ws.ready_state() != WebSocket::OPEN) + .get_value() + .map_or(false, |ws: WebSocket| ws.ready_state() != WebSocket::OPEN) { reconnect_timer_ref.set_value( set_timeout_with_handle( @@ -325,7 +325,7 @@ where }, Duration::from_millis(reconnect_interval), ) - .ok(), + .ok(), ); } })) @@ -369,7 +369,7 @@ where } #[cfg(debug_assertions)] - let zone = diagnostics::SpecialNonReactiveZone::enter(); + let zone = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_open(e); @@ -410,7 +410,7 @@ where let txt = String::from(&txt); #[cfg(debug_assertions)] - let zone = diagnostics::SpecialNonReactiveZone::enter(); + let zone = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_message_raw(&txt); @@ -420,8 +420,7 @@ where match C::decode_str(&txt) { Ok(val) => { #[cfg(debug_assertions)] - let prev = - diagnostics::SpecialNonReactiveZone::enter(); + let prev = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_message(&val); @@ -442,7 +441,7 @@ where let array = array.to_vec(); #[cfg(debug_assertions)] - let zone = diagnostics::SpecialNonReactiveZone::enter(); + let zone = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_message_raw_bytes(&array); @@ -452,7 +451,7 @@ where match C::decode_bin(array.as_slice()) { Ok(val) => { #[cfg(debug_assertions)] - let prev = diagnostics::SpecialNonReactiveZone::enter(); + let prev = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_message(&val); @@ -488,7 +487,7 @@ where } #[cfg(debug_assertions)] - let zone = diagnostics::SpecialNonReactiveZone::enter(); + let zone = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_error(UseWebSocketError::Event(e)); @@ -517,7 +516,7 @@ where } #[cfg(debug_assertions)] - let zone = diagnostics::SpecialNonReactiveZone::enter(); + let zone = leptos::reactive_graph::diagnostics::SpecialNonReactiveZone::enter(); on_close(e);