diff --git a/graphene_django/filter/fields.py b/graphene_django/filter/fields.py index 9aa629f..7c85e9a 100644 --- a/graphene_django/filter/fields.py +++ b/graphene_django/filter/fields.py @@ -35,17 +35,16 @@ class DjangoFilterConnectionField(DjangoConnectionField): @property def filterset_class(self): if not self._filterset_class: - if not self.node_type._meta.filterset_class: - fields = self._fields or self.node_type._meta.filter_fields - meta = dict(model=self.model, fields=fields) - if self._extra_filter_meta: - meta.update(self._extra_filter_meta) + fields = self._fields or self.node_type._meta.filter_fields + meta = dict(model=self.model, fields=fields) + if self._extra_filter_meta: + meta.update(self._extra_filter_meta) - self._filterset_class = get_filterset_class( - self._provided_filterset_class, **meta - ) - else: - self._filterset_class = self.node_type._meta.filterset_class + filterset_class = self._provided_filterset_class or ( + self.node_type._meta.filterset_class) + self._filterset_class = get_filterset_class( + filterset_class, **meta + ) return self._filterset_class