other types of enviros

This commit is contained in:
sbyrd 2023-05-11 20:07:19 -04:00
parent e868538be7
commit 19cf292ca0
2 changed files with 3 additions and 2 deletions

View File

@ -10,7 +10,7 @@ License: MINE-all-mine
*/
$constant_requirements = ['WP_ENVIRONMENT_TYPE'=>'staging'];
$constant_requirements = ['WP_ENVIRONMENT_TYPE'=>'staging','dev','development','sandbox'];
$plugins = ['fluent-smtp/fluent-smtp.php'];
//Loop through our constants requirements

View File

@ -12,7 +12,7 @@ License: MINE-all-mine
require_once(ABSPATH . 'wp-admin/includes/plugin.php');
$constant_requirements = ['WP_ENVIRONMENT_TYPE'=>'staging'];
$constant_requirements = ['WP_ENVIRONMENT_TYPE'=>'staging','dev','development','sandbox'];
$plugins = ['fluent-smtp/fluent-smtp.php'];
//Loop through our constants requirements
@ -22,6 +22,7 @@ foreach($constant_requirements as $constant => $requirement)
{
//Our constant requirement is meet. Plugins need to be disabled
deactivate_plugins($plugins);
add_filter('pre_wp_mail', 'staging_mail_disabler');
break; // We only need one constant requirement to be meet
}
}