ElasticPress
ElasticPress copied to clipboard
Multiple Required Features (Issue 4123 Req 5)
Description of the Change
There is already support for a singular required feature:
$this->requires_feature = 'search';
This change adds support for multiple:
$this->requires_features = ['search', 'autosuggest'];
While retaining support for a singular required feature.
How to test the Change
Add $this->requires_features = ['feature_slug_1', 'feature_slug_2']; to a Feature's constructor
Changelog Entry
Added - Ability for a feature to require multiple other features, instead of just one
Credits
Props @ZacharyRener
Checklist:
- [x] I agree to follow this project's Code of Conduct.
- [x] I have updated the documentation accordingly.
- [x] I have added Critical Flows, Test Cases, and/or End-to-End Tests to cover my change.
- [x] All new and existing tests pass.