 (defn get-invite
   [invite-id]
   (some-> (d/pull (d/db conn)
-              [:invite/id
-               {:invite/from [:user/id :user/email :user/nickname]}
-               :invite/to
-               {:invite/group [:group/id :group/name]}]
-              [:invite/id invite-id])
-      db->invitation))
+                  [:invite/id
+                   {:invite/from [:user/id :user/email :user/nickname]}
+                   :invite/to
+                   {:invite/group [:group/id :group/name]}]
+                  [:invite/id invite-id])
+          db->invitation))
 
 (defn retract-invitation!
   [invite-id]

  ; upsert-thread
  (when-not (d/entity (d/db conn) [:thread/id thread-id])
    (d/transact conn (concat [{:db/id (d/tempid :entities)
                                 :thread/id thread-id
                                 :thread/group [:group/id group-id]}])))

  (let [; for users subscribed to mentioned tags, open and subscribe them to
        ; the thread

  [attrs]
  (let [new-id (d/tempid :entities)
        {:keys [db-after tempids]} @(d/transact conn
                                      [(assoc attrs :db/id new-id)])]
    (->> (d/resolve-tempid db-after tempids new-id)
         (d/entity db-after))))

