Project

General

Profile

Actions

Bug #90165

closed

Incorrect comparison in indexed_search SearchController do not set configured languageUid

Added by form4 GmbH & Co. KG over 4 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Indexed Search
Target version:
-
Start date:
2020-01-21
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
7.2
Tags:
Complexity:
no-brainer
Is Regression:
Sprint Focus:

Description

The indexed_search SearchController->initialize() function creates the wrong languageUid in search settings.

The condition

if ($searchData['languageUid'] ?? '' === 'current')

is true, if the $searchData['languageUid'] is set. The value of the $searchData['languageUid'] doesn't matter.

This is the case, because the

'' === 'current'

comparission is evaluated first, than the

$searchData['languageUid'] ?? false

operator.

The correct condition would be

if (($searchData['languageUid'] ?? '') === 'current')
Actions

Also available in: Atom PDF