From 94ca2634a568d4d6d564e6281623fdfe7d17a3b3 Mon Sep 17 00:00:00 2001 From: Mahdi Haghverdi Date: Thu, 7 Jul 2022 06:45:34 +0430 Subject: [PATCH] fix wrong type annotation for properties parameter in Object type --- typesystem/fields.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/typesystem/fields.py b/typesystem/fields.py index 2d47d5a..b933a2a 100644 --- a/typesystem/fields.py +++ b/typesystem/fields.py @@ -409,7 +409,7 @@ class Object(Field): def __init__( self, *, - properties: typing.Dict[str, Field] = None, + properties: typing.Union[Field, typing.Dict[str, Field]] = None, pattern_properties: typing.Dict[str, Field] = None, additional_properties: typing.Union[bool, None, Field] = True, property_names: Field = None,