diff --git a/index.php b/index.php index 7d8fe56dd..fc458e605 100644 --- a/index.php +++ b/index.php @@ -54,7 +54,11 @@ * NOTE: If you change these, also change the error_reporting() code below */ #define('ENVIRONMENT', isset($_SERVER['CI_ENV']) ? $_SERVER['CI_ENV'] : 'development'); - define('ENVIRONMENT', 'development'); + if (file_exists('.debug')) { + define('ENVIRONMENT', 'development'); + } else { + define('ENVIRONMENT', 'production'); + } /* *---------------------------------------------------------------