facetwp ignore sticky posts in blog archive

djrmom

{{gist file=”custom-hooks.php” lang=”php”}}
<?php add_filter( ‘pre_get_posts’, function( $query ) {
if ( $query->is_main_query() && is_home() ) {
$query->set( ‘ignore_sticky_posts’, true );
}
});
{{/gist}}