From 2f3bb4d6d53dac31f0f86b61fb2c3110a93be2ba Mon Sep 17 00:00:00 2001 From: Adrian Wannenmacher Date: Wed, 12 Apr 2023 19:48:27 +0200 Subject: [PATCH] make clippy happy --- packages/router/src/components/link.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/packages/router/src/components/link.rs b/packages/router/src/components/link.rs index 24374bda8..8471d95e4 100644 --- a/packages/router/src/components/link.rs +++ b/packages/router/src/components/link.rs @@ -185,10 +185,8 @@ pub fn Link<'a>(cx: Scope<'a, LinkProps<'a>>) -> Element { let do_default = onclick.is_none() || !onclick_only; let action = move |event| { - if do_default { - if is_router_nav { - let _ = sender.unbounded_send(RouterMessage::Push(target.clone())); - } + if do_default && is_router_nav { + let _ = sender.unbounded_send(RouterMessage::Push(target.clone())); } if let Some(handler) = onclick {