I hereby claim:
- I am kylecbrodie on github.
- I am 0_based_kyle (https://keybase.io/0_based_kyle) on keybase.
- I have a public key ASBS5E1RWBThgpf1X043AO6GBnQBRJu9iHCponF66DUhKAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
(defn filter-map | |
"Returns a map with only the pairs that (pred key value) returned true" | |
[pred m] | |
(select-keys m (filter #(pred % (m %)) (keys m)))) | |
(defn clean-map | |
"Takes a map and removes all nil's, empty data structs, and | |
falses as these can be implied by them not being there." | |
[m] | |
(filter-map (fn [key val] (if (or (true? val) |