diff options
author | Andrey Andreev <narf@bofh.bg> | 2012-07-10 10:28:00 +0200 |
---|---|---|
committer | Andrey Andreev <narf@bofh.bg> | 2012-07-10 10:28:00 +0200 |
commit | 036b33b5151caf7950610a35d07cd174001d28c1 (patch) | |
tree | f146c1205049b99cee12f43451c0abb354f927e8 /index.php | |
parent | c25d9aa24c02a02afd1165d598c3d6d4383ac9e1 (diff) | |
parent | 8d021e647f6a094b6097d1ea89119a4047efc8dd (diff) |
Merge pull request #1398 from gintsmurans/develop
Change error_reporting(0) to ini_set('display_errors', 0);
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 29 |
1 files changed, 15 insertions, 14 deletions
@@ -52,20 +52,21 @@ * By default development will show errors but testing and live will hide them. */ -if (defined('ENVIRONMENT')) +switch (ENVIRONMENT) { - switch (ENVIRONMENT) - { - case 'development': - error_reporting(-1); - break; - case 'testing': - case 'production': - error_reporting(0); - break; - default: - exit('The application environment is not set correctly.'); - } + case 'development': + error_reporting(-1); + ini_set('display_errors', 1); + break; + + case 'testing': + case 'production': + error_reporting(E_ALL ^ E_NOTICE ^ E_DEPRECATED ^ E_STRICT); + ini_set('display_errors', 0); + break; + + default: + exit('The application environment is not set correctly.'); } /* @@ -268,4 +269,4 @@ if (defined('ENVIRONMENT')) require_once BASEPATH.'core/CodeIgniter.php'; /* End of file index.php */ -/* Location: ./index.php */
\ No newline at end of file +/* Location: ./index.php */ |