This commit is contained in:
Jonathan Kim 2019-06-25 10:15:03 +01:00
parent c5d170cb84
commit 58e770fbaa

View File

@ -192,4 +192,4 @@ class ErrorType(ObjectType):
@classmethod @classmethod
def from_errors(cls, errors): def from_errors(cls, errors):
data = camelize(errors) if graphene_settings.CAMELCASE_ERRORS else errors data = camelize(errors) if graphene_settings.CAMELCASE_ERRORS else errors
return [ErrorType(field=key, messages=value) for key, value in data.items()] return [cls(field=key, messages=value) for key, value in data.items()]