Skip to content

Instantly share code, notes, and snippets.

@himerzi
Created November 18, 2013 16:04
Show Gist options
  • Save himerzi/7530325 to your computer and use it in GitHub Desktop.
Save himerzi/7530325 to your computer and use it in GitHub Desktop.
(defn weather-find [something]
(let [ response (http/get (str weather-api "find")
{:query-params {:q something}
:as :json})]
(:body response)))
(defn get-london []
(weather-find "London"))
;; This is broken and I don't understand why
(defn get-londons []
(map #(:sys %) (:list get-london)))
;; This works, and I don't understand why
(defn get-londons-2 []
(map #(:sys %) (:list (weather-find "London"))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment