From 9a7088d937de3fcaf56cfb15c262ed28ab6f66df Mon Sep 17 00:00:00 2001 From: "deepsource-autofix[bot]" <62050782+deepsource-autofix[bot]@users.noreply.github.com> Date: Thu, 1 Jul 2021 03:30:23 +0000 Subject: [PATCH] Remove `return` from `__init__()` method --- contentcuration/contentcuration/utils/pagination.py | 2 +- contentcuration/contentcuration/viewsets/base.py | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/contentcuration/contentcuration/utils/pagination.py b/contentcuration/contentcuration/utils/pagination.py index 0bd5abef97..11964ec3dd 100644 --- a/contentcuration/contentcuration/utils/pagination.py +++ b/contentcuration/contentcuration/utils/pagination.py @@ -26,7 +26,7 @@ def __init__(self, object_list, *args, **kwargs): raise TypeError("ValuesViewsetPaginator is only intended for use with Querysets") self.queryset = object_list object_list = object_list.values_list("pk", flat=True).distinct() - return super(ValuesViewsetPaginator, self).__init__(object_list, *args, **kwargs) + super(ValuesViewsetPaginator, self).__init__(object_list, *args, **kwargs) def _get_page(self, object_list, *args, **kwargs): pks = list(object_list) diff --git a/contentcuration/contentcuration/viewsets/base.py b/contentcuration/contentcuration/viewsets/base.py index c044043eb1..2fdb43f03c 100644 --- a/contentcuration/contentcuration/viewsets/base.py +++ b/contentcuration/contentcuration/viewsets/base.py @@ -436,7 +436,6 @@ def __init__(self, *args, **kwargs): if not isinstance(self.field_map, dict): raise TypeError("field_map must be defined as a dict") self._field_map = self.field_map.copy() - return viewset @classmethod def id_attr(cls):