Fork me on GitHub
#specter
<
2020-09-15
>
jsabeaudry17:09:15

Which predicate to use to only transform if the key is present? for example (transform [:a ?] inc {:b 2})

jsabeaudry18:09:33

Yup, exactly! Thank you!

👍 3
phronmophobic17:09:08

> (spec/transform [spec/ALL (spec/must :a)] inc [{:b 2}
                                                 {:a 2}])
[{:b 2} {:a 3}]