diff --git a/src/Dev/Deprecation.php b/src/Dev/Deprecation.php index d74b7bf45..6df48894a 100644 --- a/src/Dev/Deprecation.php +++ b/src/Dev/Deprecation.php @@ -234,13 +234,13 @@ class Deprecation public static function isEnabled(): bool { - if (!Director::isDev()) { - return false; - } if (Environment::hasEnv('SS_DEPRECATION_ENABLED')) { $envVar = Environment::getEnv('SS_DEPRECATION_ENABLED'); return self::varAsBoolean($envVar); } + if (!Director::isDev()) { + return false; + } return static::$currentlyEnabled; }