diff --git a/src/wanijo/instance/view.clj b/src/wanijo/instance/view.clj index f8a637b..5094396 100644 --- a/src/wanijo/instance/view.clj +++ b/src/wanijo/instance/view.clj @@ -53,7 +53,7 @@ " | " [:a {:href (path :instance-edit-form instance)} "Edit Instance"]]] - (when-not (empty? (:properties instance)) + (when (seq (:properties instance)) [:section.properties [:h2 "Properties"] (for [prop (:properties instance) @@ -67,7 +67,7 @@ [:div {:class (str "instance-content " "attr-type-" type)} (render-fn (:value prop))]))]) - (when-not (empty? (:links-out instance)) + (when (seq (:links-out instance)) [:section.links [:h2 "Outgoing Links"] [:table @@ -90,8 +90,8 @@ {:schema-uuid (:uuid schema)})} (h (:name schema))]] [:td (prettify-dt (:created_at link))]])]]]) - (when (or (not (empty? (:links-out instance))) - (not (empty? (:links-in instance)))) + (when (or (seq (:links-out instance)) + (seq (:links-in instance))) [:section.visualisation [:h2 "Visualisation"] [:image {:src (path :instance-link-viz instance) @@ -114,7 +114,7 @@ (hform/form-to [:delete (path :instance-delete instance)] (anti-forgery-field) (view/delete-btn)) - (when-not (empty? (:links-out instance)) + (when (seq (:links-out instance)) [:section.links [:h2 "Outgoing Links"] [:table