Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RTDFacetedSearch: pass filters in one way only #7032

Merged
merged 2 commits into from May 12, 2020
Merged

RTDFacetedSearch: pass filters in one way only #7032

merged 2 commits into from May 12, 2020

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented May 6, 2020

Currently, we can pass filters as keywords (if they match a valid
filter) or in the filters keyword.

The original model FacetedSearch allows to pass filter only using the
filfilters keyword.

All places were refactored so we always pass the filters in the filters
arg.

stsewd added 2 commits May 6, 2020
Currently, we can pass filters as keywords (if they match a valid
filter) or in the `filters` keyword.

The original model FacetedSearch allows to pass filter only using the
filfilters keyword.

All places were refactored so we always pass the filters in the filters
arg.
@stsewd stsewd requested a review from May 6, 2020
def __init__(self, user, **kwargs):
"""Custom wrapper around FacetedSearch."""

operators = []
Copy link
Member Author

@stsewd stsewd May 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added it here to make it clear this is a custom attribute, not something from the original FacetedSearch class


operators = []

def __init__(self, query=None, filters=None, user=None, **kwargs):
Copy link
Member Author

@stsewd stsewd May 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also, user and filter_by_user isn't being used in neither, .org or .com. I'll remove that after this PR is merged.

@stsewd stsewd merged commit f0f2501 into master May 12, 2020
2 checks passed
@stsewd stsewd deleted the use-same-interface branch May 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants