• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Fixed Wrong variable in XenES_Search_SourceHandler_ElasticSearch

Affected version
1.1.7

Zenexer

Active member
#1
File: library/XenES/Search/SourceHandler/ElasticSearch.php
Line: 1113
Class: XenES_Search_SourceHandler_ElasticSearch
Method: isIndexSuccessful

Problematic line:
PHP:
$typeAndId = XenES_Api::getTypeAndIdFromHit($result);
$record is the wrong variable here and will result in an exception. getTypeAndIdFromHit expects $record to be passed instead.
 

Mike

XenForo developer
Staff member
#2
Just to clarify based on something in the original post, $result is the wrong variable. $record is correct. The line should be:
Code:
$typeAndId = XenES_Api::getTypeAndIdFromHit($record);
So fixed now, thanks.

In terms of when this will be triggered, it would generally just cover up another error that has been triggered during bulk indexing, so it definitely shouldn't be common.