Generator is failing on enums as well.
goors opened this issue · comments
Nikola commented
I got in swagger like someStatus
oneOf SomeStatusEnum
but that is generated like someStatus: [String: Any]
, and that is wrong since SomeStatusEnum can be Active=1, NotActive=0. So imagine I have like tons of that enum dudes and I have to remember all the values instead of saying something like SomeStatusEnum.Active
.
So the way this is generated is more of less useless.
Nikola commented
Look at the raw request for this:
{"someStatus":{"0":1}}
Instead of {"someStatus":1}
Yonas Kolb commented
It sounds like you need to be using enum instead of oneOf in your spec. You'll need to provide some more information