From 2c9a43c263300442f82efd9f740bd063606287b6 Mon Sep 17 00:00:00 2001 From: Rebecca Hum <16962021+rebeccahum@users.noreply.github.com> Date: Mon, 25 Sep 2023 12:28:06 -0600 Subject: [PATCH 1/2] Fix " Undefined constant "VIP_GO_APP_ENVIRONMENT" in /var/www/html/wp-content/mu-plugins/dev-env-plugin.php:103" --- dev-tools/dev-env-plugin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev-tools/dev-env-plugin.php b/dev-tools/dev-env-plugin.php index 7843fd39..471b8046 100644 --- a/dev-tools/dev-env-plugin.php +++ b/dev-tools/dev-env-plugin.php @@ -100,7 +100,7 @@ function dev_env_add_admin( $args, $assoc_args ) { add_action( 'init', 'dev_env_auto_login' ); function dev_env_auto_login() { - if ( 'local' !== VIP_GO_APP_ENVIRONMENT ) { + if ( defined( 'VIP_GO_APP_ENVIRONMENT' ) && 'local' !== VIP_GO_APP_ENVIRONMENT ) { return; } From 8392339920ccf62cb678d370a96230704d4eedb0 Mon Sep 17 00:00:00 2001 From: Rebecca Hum <16962021+rebeccahum@users.noreply.github.com> Date: Mon, 25 Sep 2023 12:30:43 -0600 Subject: [PATCH 2/2] Adjust logic for undefined --- dev-tools/dev-env-plugin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev-tools/dev-env-plugin.php b/dev-tools/dev-env-plugin.php index 471b8046..fcaf706d 100644 --- a/dev-tools/dev-env-plugin.php +++ b/dev-tools/dev-env-plugin.php @@ -100,7 +100,7 @@ function dev_env_add_admin( $args, $assoc_args ) { add_action( 'init', 'dev_env_auto_login' ); function dev_env_auto_login() { - if ( defined( 'VIP_GO_APP_ENVIRONMENT' ) && 'local' !== VIP_GO_APP_ENVIRONMENT ) { + if ( ! defined( 'VIP_GO_APP_ENVIRONMENT' ) || 'local' !== VIP_GO_APP_ENVIRONMENT ) { return; }