Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add API routes and controllers for additional search views #2853
Add API routes and controllers for additional search views #2853
Changes from all commits
22ba931
56139fa
09f245c
383bf3c
0052350
f6713df
419c0df
79bf445
545d45e
7317ca7
03f79fb
e4fc8e8
9666f0b
8a72ad3
2b30643
3248289
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Just a gripe/wondering what other approaches exist, no real suggestion here or request for changes)
I wish it was possible to isolate the strategy-specific and generic stuff in this method. The only way that comes to mind is to create the
Search
object before the strategy check and then pass it for mutation into thebuild_*_query
functions, but maybe that's harder to follow. Or going full OOP strategy pattern to isolate things, but that doesn't seem worth it either, unless the strategies got a lot more complex.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've extracted
build_query
to make this part a bit clearer.