Fork me on GitHub
#reitit
<
2021-06-13
>
roklenarcic08:06:58

How do I make coercion work in nested fashion

roklenarcic08:06:00

["/stats/{project-id}"
 {:parameters {:path [:map [:project-id int?]]}}
 ["/{file}/stats" {:get {:parameters {:path [:map [:file string?]]}
                         :handler get-file-stats}}]]

roklenarcic08:06:10

This only gives me :project-id in the map

ikitommi08:06:33

@roklenarcic it's a bug, with all coercion imps, mostly visible with malli

roklenarcic08:06:26

So the only workaround is to specify full parameters at each endpoint

ikitommi09:06:47

sadly, yes.