   [_]
   {:id (gen-uuid)})
 
-(defmethod set-session-cookie :default
-  [_ response session]
-  (update-response {} response
-    (set-cookie :session-id (session :id))))
+(defmethod session-cookie :default
+  [_ new? session]
+  (if (not new?)
+    (session :id)))
 
 ;; In memory sessions
 

(defn- get-response-session
  "Retrieve the current session from the response map."
  [request response]
  (assoc (:session response)
    :id (-> request :session :id)))

(defn with-session
  "Wrap a handler in a session."

  "Remove the session from the session store."
  (fn [type session] type))

(defmulti session-cookie
  "Return the session data to be stored in the cookie. This is usually the
  session ID."
  (fn [type new? session] type))

;; Default implementations of create-session and set-session-cookie

