From 877341483c6931ca2f9a33789ce71ca23926ff91 Mon Sep 17 00:00:00 2001 From: Rami Chowdhury Date: Mon, 9 Dec 2024 23:02:32 -0500 Subject: [PATCH] Remove argument --- graphene_pydantic/inputobjecttype.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/graphene_pydantic/inputobjecttype.py b/graphene_pydantic/inputobjecttype.py index 95f444d..08e4960 100644 --- a/graphene_pydantic/inputobjecttype.py +++ b/graphene_pydantic/inputobjecttype.py @@ -80,8 +80,8 @@ def __init_subclass_with_meta__( _meta=None, **options, ): - assert model and issubclass( - model, pydantic.BaseModel + assert ( + model and issubclass(model, pydantic.BaseModel) ), f'You need to pass a valid Pydantic model in {cls.__name__}.Meta, received "{model}"' assert isinstance( @@ -149,8 +149,6 @@ def resolve_placeholders(cls): model=target_type.model, ) fields_to_update[name] = graphene_field - meta.registry.register_object_field( - cls, name, pydantic_field, model=target_type.model - ) + meta.registry.register_object_field(cls, name, pydantic_field) # update the graphene side of things meta.fields.update(fields_to_update)