Code Duplication    Length = 11-14 lines in 2 locations

manager/processors/execute_module.processor.php 1 location

@@ 90-103 (lines=14) @@
87
	if (isset($php_errormsg))
88
	{
89
		$error_info = error_get_last();
90
        switch($error_info['type'])
91
        {
92
        	case E_NOTICE :
93
        		$error_level = 1;
94
        	case E_USER_NOTICE :
95
        		break;
96
        	case E_DEPRECATED :
97
        	case E_USER_DEPRECATED :
98
        	case E_STRICT :
99
        		$error_level = 2;
100
        		break;
101
        	default:
102
        		$error_level = 99;
103
        }
104
		if($modx->config['error_reporting']==='99' || 2<$error_level)
105
		{
106
			$modx->messageQuit('PHP Parse Error', '', true, $error_info['type'], $error_info['file'], $_SESSION['itemname'] . ' - Module', $error_info['message'], $error_info['line'], $msg);

manager/includes/document.parser.class.inc.php 1 location

@@ 6285-6295 (lines=11) @@
6282
        if (isset($actionName) && !empty($actionName)) {
6283
            $source .= $actionName;
6284
        }
6285
        switch ($nr) {
6286
            case E_DEPRECATED :
6287
            case E_USER_DEPRECATED :
6288
            case E_STRICT :
6289
            case E_NOTICE :
6290
            case E_USER_NOTICE :
6291
                $error_level = 2;
6292
                break;
6293
            default:
6294
                $error_level = 3;
6295
        }
6296
        $this->logEvent(0, $error_level, $str, $source);
6297
6298
        if ($error_level === 2 && $this->error_reporting !== '99') {