I found a bug in the Similar Threads Addon , when using enhanced search,
it is possible in come circumstances for the method getSimilarThreadsEnhanced to receive a
NULL value for "currentNodeId".
This is passed into the Elastic Search query unchecked , this causes a lot of Server Errors (something like this)
of request to elastic search that we know will fail before they are sent.
My fix , is to just
if (!$currentNodeId){
return;
}
right after the check for excluded forums (line 527).
This prevents the query from being sent and acts as if no results were returned.
Please could you look into this and maybe patch the plugin so that we dont have to
manage updates seperately?
Thanks
Nick
it is possible in come circumstances for the method getSimilarThreadsEnhanced to receive a
NULL value for "currentNodeId".
This is passed into the Elastic Search query unchecked , this causes a lot of Server Errors (something like this)
- GuzzleHttp\Exception\ClientException: Similar threads error: Client error:
POST http://{OBFUSCATED AWS ES URL }/xenforo-prod/xf/_search
resulted in a400 Bad Request
response: {"error":{"root_cause":[{"type":"illegal_argument_exception","reason":"field name is null or empty"}],"type":"illegal_ar (truncated...) - src/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:113
of request to elastic search that we know will fail before they are sent.
My fix , is to just
if (!$currentNodeId){
return;
}
right after the check for excluded forums (line 527).
This prevents the query from being sent and acts as if no results were returned.
Please could you look into this and maybe patch the plugin so that we dont have to
manage updates seperately?
Thanks
Nick