File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed
lib/livebook_web/live/session_live Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -98,7 +98,7 @@ defmodule LivebookWeb.SessionLive.AppInfoComponent do
98
98
</ h3 >
99
99
100
100
< div class = "flex flex-col mt-2 space-y-4 " >
101
- < div :if = { app_has_sessions? ( @ app ) } class = "flex flex-col space-y-3 " >
101
+ < div :if = { @ app } class = "flex flex-col space-y-3 " >
102
102
< . labeled_text label = "URL " one_line >
103
103
< a href = { ~p" /apps/#{ @ app . slug } " } >
104
104
{ ~p" /apps/#{ @ app . slug } " }
@@ -118,9 +118,9 @@ defmodule LivebookWeb.SessionLive.AppInfoComponent do
118
118
</ div >
119
119
</ div >
120
120
121
- < div class = { [ "grid gap-2" , app_has_sessions? ( @ app ) && "grid-cols-2" ] } >
121
+ < div class = { [ "grid gap-2" , @ app && "grid-cols-2" ] } >
122
122
< span class = "flex flex-col " >
123
- <%= if app_has_sessions? ( @ app ) do %>
123
+ <%= if @ app do %>
124
124
< . button color = "gray " outlined phx-click = "deploy_app " >
125
125
< . remix_icon icon = "slideshow-4-line " /> Relaunch
126
126
</ . button >
@@ -131,7 +131,7 @@ defmodule LivebookWeb.SessionLive.AppInfoComponent do
131
131
<% end %>
132
132
</ span >
133
133
< . button
134
- :if = { app_has_sessions? ( @ app ) }
134
+ :if = { @ app }
135
135
color = "red "
136
136
outlined
137
137
type = "button "
@@ -215,10 +215,6 @@ defmodule LivebookWeb.SessionLive.AppInfoComponent do
215
215
"""
216
216
end
217
217
218
- defp app_has_sessions? ( app ) do
219
- app && app . sessions != [ ]
220
- end
221
-
222
218
defp app_info_icon ( assigns ) do
223
219
~H"""
224
220
< span
You can’t perform that action at this time.
0 commit comments