Skip to content

Commit

Permalink
* Try not to show the full path to the current PHP file in public err…
Browse files Browse the repository at this point in the history
…or messages. It's just a matter of privacy. (Errors.php)
  • Loading branch information
Nao committed Feb 20, 2017
1 parent 0f35c9a commit 2f6ef2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/app/Errors.php
Expand Up @@ -304,7 +304,7 @@ function error_handler($error_level, $error_string, $file, $line)

// Debugging! This should look like a PHP error message.
echo '<br>
<strong>', $error_level % 255 == E_ERROR ? 'Error' : ($error_level % 255 == E_WARNING ? 'Warning' : 'Notice'), '</strong>: ', $error_string, ' in <strong>', $file, '</strong> on line <strong>', $line, '</strong><br>';
<strong>', $error_level % 255 == E_ERROR ? 'Error' : ($error_level % 255 == E_WARNING ? 'Warning' : 'Notice'), '</strong>: ', $error_string, ' in <strong>', basename($file), '</strong> on line <strong>', $line, '</strong><br>';
}

$error_type = strpos(strtolower($error_string), 'undefined') !== false ? 'undefined_vars' : 'general';
Expand Down

0 comments on commit 2f6ef2a

Please sign in to comment.