: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
* Builder Plugin Compatibility Code
* @package Themify_Builder
* @subpackage Themify_Builder/classes
class Themify_Builder_Plugin_Compat_EnviraGallery {
add_filter( 'themify_builder_post_types_support', array( __CLASS__, 'themify_builder_post_types_support' ), 12, 1 );
add_filter( 'themify_post_types',array( __CLASS__, 'themify_builder_post_types_support' ), 12, 1 );
* Filter builder post types compatibility
public static function themify_builder_post_types_support(array $post_types):array{
$post_types = array_keys(array_flip($post_types));
$exclude = array_search('envira', $post_types,true);
unset($post_types[$exclude]);
$exclude = array_search('envira_album', $post_types,true);
unset($post_types[$exclude]);