ownership = $ownership; } public function register() { $modules = array( new WooCommerceCacheExclusion(), new NonceFormExclusion(), new SwiftPressSupport(), new SwiftCartSupport(), new SwiftBlocksSupport(), new ElementorSupport(), new BeaverBuilderSupport(), new GutenbergSupport(), new RankMathSupport(), new YoastSupport(), new WPFormsSupport(), new GravityFormsSupport(), new ContactForm7Support(), new FluentFormsSupport(), new WordfenceSupport(), ); foreach ( $modules as $module ) { $module->register(); } add_filter( 'nbh_performance_should_optimize_feature', array( $this, 'owns_feature' ), 10, 2 ); do_action( 'nbh_performance_compatibility_registered', $this->ownership->owners() ); } public function owner( $feature ) { return $this->ownership->owner( $feature ); } public function nbh_performance_owns( $feature ) { return $this->ownership->owns( $feature ); } public function owns_feature( $allowed, $feature ) { return $allowed && $this->nbh_performance_owns( $feature ); } }