Project

General

Profile

Actions

Task #93738

closed

getSearchWords-Hook has different registration-name and function to call

Added by Tina Westner about 3 years ago. Updated over 2 years ago.

Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
Indexed Search
Start date:
2021-03-15
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
11
PHP Version:
7.4
Tags:
Complexity:
no-brainer
Sprint Focus:

Description

-- new issue created from https://forge.typo3.org/issues/75845#note-1 by Robert Vock--

It is also not possible to use the hook in getSearchWords correctly.

The hook expects a function 'getSearchWords' in the hook object, but calls 'getSearchWords_splitSWords'. To use the hook, you need a class, which has both methods. The first will never be called, but SearchController->hookRequest checks for it's existence:
https://github.com/TYPO3/TYPO3.CMS/blob/master/typo3/sysext/indexed_search/Classes/Controller/SearchController.php#L907

The problem is here, that the hook is only valid, if function name "getSearchWords" exists in hook-class. But when calling the hook, the function "getSearchWords_splitSWords" is being called.

In any other places, the registration name and the called method name are equal.

The bugfix is a breaking change, because all people, who use this hook have to change the hook-registration in ext_localconf.


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #75845: getSearchWords does not work with sentencesClosed2016-04-21

Actions
Actions

Also available in: Atom PDF