diff --git a/inc/mod/config-editor.php b/inc/mod/config-editor.php index 688b0910..9c8dfb30 100644 --- a/inc/mod/config-editor.php +++ b/inc/mod/config-editor.php @@ -103,7 +103,13 @@ function config_vars() { continue; // This is just an alias. if (!preg_match('/^array|\[\]|function/', $var['default']) && !preg_match('/^Example: /', trim(implode(' ', $var['comment'])))) { $syntax_error = true; - $temp = eval('$syntax_error = false;return @' . $var['default'] . ';'); + try { + $temp = $var['default']; + $syntax_error = false; + } + catch (Exception $e) { + $temp = false; + } if ($syntax_error && $temp === false) { error('Error parsing config.php (line ' . $line_no . ')!', null, $var); } elseif (!isset($temp)) {