Skip to content
Snippets Groups Projects
Commit 52d38a0c authored by stuebinm's avatar stuebinm
Browse files

cwality-maps: also traverse generic aeson values

this works surprisingly well, actually
parent 833186af
No related branches found
No related tags found
No related merge requests found
......@@ -53,7 +53,12 @@ trivial :: t -> b -> ([a], t)
trivial = const . ([],)
instance {-# OVERLAPS #-} Substitutable A.Value where
substitute = trivial
substitute (A.Object fields) params =
second A.Object $ traverse (`substitute` params) fields
substitute (A.String str) params =
second A.String $ substitute str params
substitute other params = ([], other)
instance Substitutable Int where
substitute = trivial
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment