[3.10] [PHP 8.1] Fixes com_finder/indexer/query#36796
[3.10] [PHP 8.1] Fixes com_finder/indexer/query#36796zero-24 merged 3 commits intojoomla:3.10-devfrom
Conversation
Fixes `Deprecated: html_entity_decode(): Passing null to parameter #1 ($string) of type string is deprecated in administrator/components/com_finder/helpers/indexer/query.php on line 733`
|
I have tested this item ✅ successfully on 834b5af This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/36796. |
Do you have a stack trace here so we know where the "null" value is comming from? As the signature clearly says "The query input string." And can you tell me what re-indexing you mean and how to trigger that in the frontend? Isnt indexing triggerd by the backend? Maybe I'm missing something here? |
Hi @zero-24,
The error appears in the Smart Search module like this: |
|
Please check: https://github.com/joomla/joomla-cms/blob/3.10-dev/administrator/components/com_finder/helpers/indexer/query.php#L175 and update it to That should do the trick too. |
Yes, it fixes it too, and as it's better typed, it's a better fix too. Thank you! Updated the PR, with mention in the commit message.. |
|
Thanks merging it here :) |

Pull Request for Issue # none
Summary of Changes
Fixes
FixesDeprecated: html_entity_decode(): Passing null to parameter #1 ($string) of type string is deprecated in administrator/components/com_finder/helpers/indexer/query.php on line 733`Testing Instructions
Code review should be enough.
Look in frontend in PHP 8.1 with all errors on and Joomla debug on, while finder is re-indexing.
Actual result BEFORE applying this Pull Request
Deprecated: html_entity_decode(): Passing null to parameter #1 ($string) of type string is deprecated in administrator/components/com_finder/helpers/indexer/query.php on line 733Expected result AFTER applying this Pull Request
warning disappeared.
Documentation Changes Required
none.