Skip to content

Commit

Permalink
check function_exists first
Browse files Browse the repository at this point in the history
  • Loading branch information
circlecube committed May 21, 2024
1 parent 00058b5 commit 08f3180
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@

namespace NewfoldLabs\WP\Module\Performance;

add_filter(
'newfold/features/filter/register',
function( $features ) {
return array_merge( $features, array( PerformanceFeature::class ) );
}
);
if ( function_exists( 'add_filter' ) ) {
add_filter(
'newfold/features/filter/register',
function( $features ) {
return array_merge( $features, array( PerformanceFeature::class ) );
}
);
}

new PerformanceFeatureHooks();

0 comments on commit 08f3180

Please sign in to comment.