Hi! I’m a developer I’m using Search Exclude plugin and I found conflict in WP Customer Area – bug is in CUAR_CustomerPagesAddOn
class, it’s makes post__not_in
not working for Search Exclude. Could you fix it please?
Conflict in this function
public function exclude_pages_from_search_results($query) { if (!is_admin() && $query->is_main_query()) { if ($query->is_search) { $customer_area_pages = $this->get_customer_area_pages(); $pages_to_exclude = []; foreach ($customer_area_pages as $slug => $page) { $pages_to_exclude[] = $page->get_page_id(); } $query->set(‘post__not_in’, $pages_to_exclude); } } }