Skip to content

Commit

Permalink
refactor: rename PythonICATSkipFilter use variable #263
Browse files Browse the repository at this point in the history
  • Loading branch information
Viktor Bozhinov committed Dec 6, 2021
1 parent d8572ed commit a474cfa
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions datagateway_api/src/datagateway_api/icat/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,12 +210,12 @@ def apply_filter(self, query):


class PythonICATSkipFilter(SkipFilter):
def __init__(self, skip_value, client_use="datagateway_api"):
def __init__(self, skip_value, filter_use="datagateway_api"):
super().__init__(skip_value)
self.client_use = client_use
self.filter_use = filter_use

def apply_filter(self, query):
if self.client_use == "datagateway_api":
if self.filter_use == "datagateway_api":
icat_properties = get_icat_properties(
config.datagateway_api.icat_url, config.datagateway_api.icat_check_cert,
)
Expand Down
2 changes: 1 addition & 1 deletion datagateway_api/src/search_api/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def apply_filter(self, query):

class SearchAPISkipFilter(PythonICATSkipFilter):
def __init__(self, skip_value):
super().__init__(skip_value, client_use="search_api")
super().__init__(skip_value, filter_use="search_api")

def apply_filter(self, query):
return super().apply_filter(query)
Expand Down

0 comments on commit a474cfa

Please sign in to comment.