- Issue created by @mile23
- @abhishek_gupta1 opened merge request.
- 🇮🇳India abhishek_virasat
@mile23, I have fixed the issue and created MR. please review it once
I was looking at BoostMoreRecent and NumberFieldBoost as a template for making my own search_api processor for Solr, but they throw errors such as:
Warning: Undefined array key "boosts" in Drupal\search_api_solr\Plugin\search_api\processor\BoostMoreRecent->submitConfigurationForm() (line 118 of modules/contrib/search_api_solr/src/Plugin/search_api/processor/BoostMoreRecent.php).
I found 🐛 Undefined array key "boosts" in BoostMoreRecent.php Fixed which tells us that things will work without error if you have the proper field types already, but I have to say that throwing a PHP error rather than an explanation doesn't seem all that kind to developer or users.
It seems like defaultConfiguration()
would get called regardless of whether a given field is of a specific type, but I guess not. Is there some way to fix this so that the notice says something nice instead of PHP error?
Active
4.3
Code
@mile23, I have fixed the issue and created MR. please review it once