Closed Wegi closed 5 years ago
Is this a dupe of #406?
Oh yeah, thanks seems like it. I'll close this one again.
I'll try to cut out a new version of spec-tools + c-api. This will be fixed in it too: https://github.com/metosin/spec-tools/issues/165
Library Version(s)
2.0.0-alpha28
Problem
When spec-coercion for the :return type is activated and a lazy sequence is passed as the result, the sequence is reversed. Does not happen with a e.g. vector.
Example:
If you open the swagger API and go to that endpoint the result will be "[5 4 3 2]". When replacing
map
withmapv
to get a nonLazy Sequence or when removing the:return
the result is"[2 3 4 5]"
as it should be.This bug reverses all lazy sequences, even if they are nested inside of multiple levels of maps.