Skip to content

Commit 5cba3f6

Browse files
committed
Fixed OneToOneField Django 1.6+ bug
1 parent e742b10 commit 5cba3f6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

graphene_django/converter.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,9 @@ def dynamic_type():
147147
if not _type:
148148
return
149149

150+
if isinstance(field.field, models.OneToOneField):
151+
return Field(_type)
152+
150153
if is_node(_type):
151154
return get_connection_field(_type)
152155
return Field(List(_type))

0 commit comments

Comments
 (0)