Fix cookie-parsing bug in the example note-taking app (#761)
This commit is contained in:
parent
8936060d42
commit
1533a2d0b5
1 changed files with 1 additions and 1 deletions
|
|
@ -88,7 +88,7 @@
|
|||
|
||||
(defn get-session-id [headers]
|
||||
(if-let [cookie-header (first (filter #(str/starts-with? % "Cookie: ") headers))]
|
||||
(let [parts (str/split cookie-header #"; ")]
|
||||
(let [parts (str/split (str/replace cookie-header "Cookie: " "") #"; ")]
|
||||
(if-let [notes-id (first (filter #(str/starts-with? % "notes-id") parts))]
|
||||
(str/replace notes-id "notes-id=" "")
|
||||
(new-session!)))
|
||||
|
|
|
|||
Loading…
Reference in a new issue