Skip to content

Commit 7888fa7

Browse files
committed
Restore django filter check
1 parent 1a04d60 commit 7888fa7

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

graphene_django/utils.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ class LazyList(object):
1111
pass
1212

1313

14-
import django_filters # noqa
15-
DJANGO_FILTER_INSTALLED = True
14+
try:
15+
import django_filters # noqa
16+
DJANGO_FILTER_INSTALLED = True
17+
except ImportError:
18+
DJANGO_FILTER_INSTALLED = False
1619

1720

1821
def get_reverse_fields(model, local_field_names):

0 commit comments

Comments
 (0)