From 7b8f07cbb3a7eff9445f084722fbbd4cb6fa7837 Mon Sep 17 00:00:00 2001 From: Jan Romann Date: Thu, 6 Jun 2024 15:42:46 +0200 Subject: [PATCH] fix(data_schema.dart): fix deserialization of required field --- lib/src/core/definitions/data_schema.dart | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/src/core/definitions/data_schema.dart b/lib/src/core/definitions/data_schema.dart index 9ed6f4bc..ca9cc0b7 100644 --- a/lib/src/core/definitions/data_schema.dart +++ b/lib/src/core/definitions/data_schema.dart @@ -92,7 +92,8 @@ class DataSchema implements Serializable { json.parseDataSchemaArrayField("items", prefixMapping, parsedFields); final minItems = json.parseField("minItems", parsedFields); final maxItems = json.parseField("maxItems", parsedFields); - final required = json.parseField>("required", parsedFields); + final required = + json.parseArrayField("required", parsedFields: parsedFields); final minLength = json.parseField("minLength", parsedFields); final maxLength = json.parseField("maxLength", parsedFields); final pattern = json.parseField("pattern", parsedFields);