- <%= Phoenix.Flash.get(@flash, :info) %>
- <%= Phoenix.Flash.get(@flash, :error) %>
+ <%= if Phoenix.Flash.get(@flash, :info) do %>
+ <%= Phoenix.Flash.get(@flash, :info) %>
+ <% end %>
+ <%= if Phoenix.Flash.get(@flash, :error) do %>
+ <%= Phoenix.Flash.get(@flash, :error) %>
+ <% end %>
<%= @inner_content %>
diff --git a/lib/mindwendel_web/templates/layout/live.html.heex b/lib/mindwendel_web/templates/layout/live.html.heex
index 9f2e10ba..fb2878cb 100644
--- a/lib/mindwendel_web/templates/layout/live.html.heex
+++ b/lib/mindwendel_web/templates/layout/live.html.heex
@@ -1,11 +1,13 @@
-
- <%= live_flash(@flash, :info) %>
-
-
-
- <%= live_flash(@flash, :error) %>
-
-
+ <%= if live_flash(@flash, :info) do %>
+
+ <%= live_flash(@flash, :info) %>
+
+ <% end %>
+ <%= if live_flash(@flash, :error) do %>
+
+ <%= live_flash(@flash, :error) %>
+
+ <% end %>
<%= @inner_content %>