diff --git a/lib/src/code_generators/swagger_models_generator.dart b/lib/src/code_generators/swagger_models_generator.dart index 19331d8b..c43ae931 100644 --- a/lib/src/code_generators/swagger_models_generator.dart +++ b/lib/src/code_generators/swagger_models_generator.dart @@ -161,6 +161,11 @@ abstract class SwaggerModelsGenerator extends SwaggerGeneratorBase { result[innerClassName] = propSchema; } }); + + if (schema.items != null) { + result.addAll(getClassesFromInnerClasses( + {'${getValidatedClassName(classKey)}\$item': schema.items!})); + } }); if (result.isNotEmpty) {