Skip to content

Instantly share code, notes, and snippets.

@Pebblo
Last active April 9, 2024 13:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Pebblo/b8e8b982f17f484887428326bebc5450 to your computer and use it in GitHub Desktop.
Save Pebblo/b8e8b982f17f484887428326bebc5450 to your computer and use it in GitHub Desktop.
<?PHP //Please do not include the opening PHP tag if you already have one
add_filter( 'FHEE__EE_Front_Controller__display_errors', 'tw_ee_disable_front_controller_display_errors' );
function tw_ee_disable_front_controller_display_errors( $enabled ) {
if( is_home() || is_front_page() ) {
return false;
}
return $enabled;
}
<?PHP //Please do not include the opening PHP tag if you already have one
add_filter( 'tw_ee_disable_front_controller_display_errors', 'tw_ee_disable_front_controller_display_errors_more' );
function tw_ee_disable_front_controller_display_errors( $enabled ) {
if(
is_home()
|| is_front_page()
|| is_post_type_archive('espresso_events')
) {
return false;
}
return $enabled;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment