library/Search/Algolia.php
public function saveExcludeFromSearch($postId)
    {
        if (!isset($_POST['algolia-exclude-from-search']) || $_POST['algolia-exclude-from-search'] != 'true') {
            delete_post_meta($postId, 'exclude_from_search');
            return;
        }
        update_post_meta($postId, 'exclude_from_search', true);
    }
public function saveExcludeFromSearch($postId)
    {
        if (!isset($_POST['algolia-exclude-from-search']) || $_POST['algolia-exclude-from-search'] != 'true') {
            delete_post_meta($postId, 'exclude_from_search');
            return;
        }
        update_post_meta($postId, 'exclude_from_search', true);
    }
public function saveExcludeFromSearch ( $ postId ) { if ( ! isset ( $ _POST [ 'algolia-exclude-from-search' ] ) || $ _POST [ 'algolia-exclude-from-search' ] != 'true' ) { delete_post_meta ( $ postId , 'exclude_from_search' ) ; return ; } update_post_meta ( $ postId , 'exclude_from_search' , true ) ; }
Saves the "exclude from search" value
@param  int $postId The post id
@return void
Saves the exclude from search value