Created
April 15, 2019 11:13
-
-
Save slipset/12af01dfac0632d4dbe40a32d96b9e8c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def urls {:vg "https://www.vg.no", :ap "https://www.ap.no", :db "https://www.db.no"} ) | |
(defn my-get-request [[k url]] | |
[k (future (http/get url))]) | |
(->> urls | |
(map my-get-request) | |
(reduce (fn [acc [k v]] | |
(assoc acc k (deref v))) {})) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
does the thing :)