Skip to content

Commit 0d41646

Browse files
committed
Fixed instance getter using _root.
1 parent d6a5269 commit 0d41646

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

graphene/contrib/django/types.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,14 @@ def __init__(self, _root=None):
4949
))
5050
super(InstanceObjectType, self).__init__(_root=_root)
5151

52+
@property
53+
def instance(self):
54+
return self._root
55+
56+
@instance.setter
57+
def instance(self, value):
58+
self._root = value
59+
5260
def __getattr__(self, attr):
5361
return getattr(self._root, attr)
5462

0 commit comments

Comments
 (0)