   "Blocks current thread until all osc messages in action-fn have
   completed. Returns result of action-fn."
   [action-fn]
-  (let [id (next-id ::server-sync-id)
+  (let [id   (next-id ::server-sync-id)
         prom (promise)
-        key (uuid)]
+        key  (uuid)]
     (on-event "/synced"
               (fn [msg] (when (= id (first (:args msg)))
                          (do

      res)))

(defn server-sync
  "Send a sync message to the server with the specified id. Server
  will reply with a synced message when all incoming messages up to
  the sync message have been handled. See with-server-sync and
  on-server-sync for more typical usage."
  [id]
  (server-snd "/sync" id))

(defn with-server-self-sync
  "Blocks the current thread until the action-fn explicitly sends a
  server sync.  The action-fn is assumed to have one argument which
  will be the unique sync id.  This is useful when the action-fn is
  itself asynchronous yet you wish to synchronise with its
  completion. The action-fn can sync using the fn server-sync.
  Returns the result of action-fn."
  [action-fn]
  (let [id (next-id ::server-sync-id)
        prom (promise)
        key (uuid)]
    (oneshot-event "/synced"
                   (fn [msg] (when (= id (first (:args msg)))
                              (deliver prom true)))

      res)))

(defn server-recv
  "Register your intent to wait for a message associated with given path
  to be received from the server. Returns a promise that will contain
  the message once it has been received. Does not block current
  thread (this only happens once you try and look inside the promise and
  the reply has not yet been received).

  If an optional matcher-fn is specified, will only deliver the promise
  when the matcher-fn returns true. The matcher-fn should accept one arg
  which is the incoming event info."
  ([path] (server-recv path nil))
  ([path matcher-fn]
     (let [p   (promise)
           key (uuid)]
       (on-sync-event path
                      (fn [info]
