icerockdev / moko-network

Network components with codegeneration of rest api for mobile (android & ios) Kotlin Multiplatform development
https://moko.icerock.dev
Apache License 2.0
151 stars 29 forks source link

Api generation error for nullable enum types #89

Closed kovalandrew closed 3 years ago

kovalandrew commented 3 years ago

If spec contains nullable enum type and one of items is null it will fail generation:

layout_name:
              title: Название шаблона отображения
              type: string
              enum:
                - null
                - layout_1
                - layout_2
                - layout_3
              nullable: true

For generation should remove - null item for success generation:

layout_name:
              title: Название шаблона отображения
              type: string
              enum:
                - layout_1
                - layout_2
                - layout_3
              nullable: true
Alex009 commented 3 years ago

will be available in 0.11.0