From 748c99d6315d99551f9e950b3888cafd321b8b58 Mon Sep 17 00:00:00 2001 From: David Vogt Date: Thu, 3 Oct 2019 15:59:25 +0200 Subject: [PATCH] fix(filters): don't pass self to super().__init__() call Don't know how this ever worked - self is passed implicitly, and passing it again breaks the filter instance in very subtle ways (but somehow still kept them working in most cases) --- caluma/form/filters.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/caluma/form/filters.py b/caluma/form/filters.py index b1057c1cb..a8f2ae9ec 100644 --- a/caluma/form/filters.py +++ b/caluma/form/filters.py @@ -94,7 +94,7 @@ class HasAnswerFilter(Filter): def __init__(self, *args, **kwargs): self.document_id = kwargs.pop("document_id") - super().__init__(self, *args, **kwargs) + super().__init__(*args, **kwargs) VALID_LOOKUPS = { "text": [ @@ -242,7 +242,7 @@ class SearchAnswersFilter(Filter): def __init__(self, *args, **kwargs): self.document_id = kwargs.pop("document_id") - super().__init__(self, *args, **kwargs) + super().__init__(*args, **kwargs) def filter(self, qs, value): if value in EMPTY_VALUES: