   ;; acts as both an index of existing items and factory for new ones
   :allowed-methods #{:get :post}
 
-  :exists? true ; This 'factory' resource ALWAYS exists
+  :exists? true                  ; This 'factory' resource ALWAYS exists
   :available-media-types base-media-types
 
-  :handle-ok ; do this upon a successful GET
+  :handle-ok                            ; do this upon a successful GET
   (fn [{{mime :media-type} :representation {routes :jig.bidi/routes route-params :route-params} :request}]
     (let [items
           (->>
            {:hecuba/type typ} ; form a 'where' clause starting with the type
-           (merge route-params) ; adding any route-params
-           (items querier) ; to query items
+           (merge route-params)         ; adding any route-params
+           (items querier)              ; to query items
            ;; which are adorned with hrefs, throwing bidi's path-for all the kv pairs we have!
-           (map #(assoc % :hecuba/href (apply path-for routes item-resource (apply concat %))))
-           (map #(assoc % :hecuba/parent-href (path-for routes parent-resource :hecuba/id (:hecuba/parent %)))))]
+           (map #(assoc %
+                   :hecuba/href (apply path-for routes item-resource (apply concat %))
+                   :hecuba/parent-href (path-for routes parent-resource :hecuba/id (:hecuba/parent %)))))]
+
       (case mime
         "text/html" (render-items-html items)
         ;; Liberator's default rendering of application/edn seems wrong

        ;; The default is to let Liberator render our data
        items)))

  :post! ; enact the 'side-effect' of creating an item
  (fn [{{body :body} :request}]
    {:hecuba/id ; add this entry to Liberator's context
     (upsert! commander
              (-> body
                  ;; Prepare to read the body

                  (for [k fields] [:td (str (k p))])
                  (when DEBUG [:td (pr-str p)])])]]]))))

;; Now for the Liberator resources. Check the Liberator website for more
;; info: http://clojure-liberator.github.io/liberator/

;; REST resource for items (plural) - .
