   "Unified asynchronous channel interface for HTTP (streaming or long-polling)
    and WebSocket."
 
-  (open? [ch] "Returns true iff channel is open.")
-  (close [ch]
+  (open?      [ch] "Returns true iff channel is open.")
+  (websocket? [ch] "Returns true iff channel is a WebSocket.")
+  (close      [ch]
     "Closes the channel. Idempotent: returns true if the channel was actually
     closed, or false if it was already closed.")
-  (websocket? [ch] "Returns true iff channel is a WebSocket.")
+
   (send! [ch data] [ch data close-after-send?]
     "Sends data to client and returns true if the data was successfully sent,
     or false if the channel is closed. Data is sent directly to the client,

  (doseq [ch @clients]
    (swap! clients disj ch)
    (send! ch {:status  200
                 :headers {\"Content-Type\" \"text/html\"}
                 :body your-async-response}
             ;; false ; Uncomment to use chunk encoding for HTTP streaming
             )))


(defn websocket-handshake-check
  "Returns `sec-ws-accept` string iff given Ring request is a valid
  WebSocket handshake."
  [ring-req]
  (when-let [sec-ws-key (get-in ring-req [:headers "sec-websocket-key"])]
    (try
      (sec-websocket-accept sec-ws-key)
