Fixed lazy type instant resolved with NonNull. Fixed #494

This commit is contained in:
Syrus Akbary 2017-07-26 22:32:37 -07:00
parent f3bdd7de69
commit 5c58d9e686

View File

@ -68,9 +68,9 @@ class NonNull(Structure):
def __init__(self, *args, **kwargs):
super(NonNull, self).__init__(*args, **kwargs)
assert not isinstance(self.of_type, NonNull), (
assert not isinstance(self._of_type, NonNull), (
'Can only create NonNull of a Nullable GraphQLType but got: {}.'
).format(self.of_type)
).format(self._of_type)
def __str__(self):
return '{}!'.format(self.of_type)