From 40c95a89b30abd2c9f4c2bc95ac40d94675c6fb2 Mon Sep 17 00:00:00 2001 From: Wout De Puysseleir Date: Thu, 2 Mar 2023 12:40:42 -0800 Subject: [PATCH] Use if instead of unless Imo is easier to understand than unless --- lib/live_component.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/live_component.ex b/lib/live_component.ex index 1663aab..599d43c 100644 --- a/lib/live_component.ex +++ b/lib/live_component.ex @@ -44,7 +44,7 @@ defmodule LiveSvelte do def update(assigns, socket) do # Making sure we only render once ssr_code = - unless connected?(socket) do + if not connected?(socket) do props = Map.get(assigns, :props, %{}) slot = ~H"""