Skip to content

Commit

Permalink
Print body for non-200 responses
Browse files Browse the repository at this point in the history
  • Loading branch information
jcrossley3 committed Aug 10, 2015
1 parent b85c7c7 commit f4cae70
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions web/dev-resources/testing/web.clj
Expand Up @@ -50,8 +50,10 @@
(with-open [client (http/create-client)]
(let [response (get-response url :headers headers :cookies cookies)]
(if (= 200 (:status response))
(:body response)
(:status response)))))
(:body response)
(do
(if-let [b (:body response)] (println b))
(:status response))))))

(defn event-source
"Returns an SSE EventSource client"
Expand Down

0 comments on commit f4cae70

Please sign in to comment.