diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/aggiedit_web/live/post_live/form_component.html.heex | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/aggiedit_web/live/post_live/form_component.html.heex b/lib/aggiedit_web/live/post_live/form_component.html.heex index 2f0738e..a956cb3 100644 --- a/lib/aggiedit_web/live/post_live/form_component.html.heex +++ b/lib/aggiedit_web/live/post_live/form_component.html.heex @@ -27,11 +27,13 @@ </div> <% end %> <%= else %> - <div class="row"> - <div class="column"> - <img style="height:80px" src={Routes.static_path(@socket, "/uploads/#{@post.upload.file}")} /> + <% if !is_nil(@post.upload) do %> + <div class="row"> + <div class="column"> + <img style="height:80px" src={Routes.static_path(@socket, "/uploads/#{@post.upload.file}")} /> + </div> </div> - </div> + <% end %> <% end %> <div> |