7, 'function' => '__construct', 'class' => 'ET_Core_PageResource' ), array( 'stack_level' => 7, 'function' => 'get_cache_filename', 'class' => 'ET_Builder_Element' ) ); /** * Initialize compatibility module * @param $sm */ public function module_init( $sm ) { // exclude randomize_filename from export if( !empty( $_GET[ 'et_core_portability' ] ) || wp_doing_ajax() && ( !empty( $_POST[ 'action' ] ) && $_POST[ 'action' ] == 'et_core_portability_export' ) || ( !empty( $_POST[ 'et_core_portability_export' ] ) && $_POST[ 'et_core_portability_export' ] == 'et_core_portability_export' ) ) { remove_filter( 'sanitize_file_name', array( "wpCloud\StatelessMedia\Utility", 'randomize_filename' ), 10 ); } // maybe skip cache busting add_filter( 'stateless_skip_cache_busting', array( $this, 'maybe_skip_cache_busting' ), 10, 2 ); } /** * Maybe skip cache busting * @param $null * @param $filename * @return bool | string */ public function maybe_skip_cache_busting( $null, $filename ) { $callstack = debug_backtrace( DEBUG_BACKTRACE_IGNORE_ARGS, 8 ); if( Utility::isCallStackMatches( $callstack, $this->cache_busting_disable_conditions ) ) return $filename; return $null; } } } }