Bug in relevanssi_default_post_ok
-
There’s a bug in the
relevanssi_default_post_ok
function. The problem is that, although it receives a$post_ok
value from earlier filter function(s), it disregards this received value and overwrites it with true or false depending on its own tests.The easiest solution is to add a, let’s say,
$my_post_ok = true;
declaration at the beginning of the function, then use this variable in the 6 instances where$post_ok
was originally used, and finally end the function with areturn ( $my_post_ok && $post_ok );
. This way an originallyfalse
$post_ok
value won’t suddenly becometrue
and make posts that should be hidden reappear in the search.What do you think?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Bug in relevanssi_default_post_ok’ is closed to new replies.