MINOR #5943 Debug::text() boolean values are amended with (bool) so they don't get confused with "true" or "false" which could be strings (thanks Pigeon!) (from r111676)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112918 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sam Minnee 2010-10-19 04:52:33 +00:00
parent 2dca48ba09
commit 25af09b0f6

View File

@ -136,6 +136,9 @@ class Debug {
} else if (is_object($val)) {
$val = var_export($val, true);
} else if (is_bool($val)) {
$val = $val ? 'true' : 'false';
$val = '(bool) ' . $val;
} else {
if(!Director::is_cli() && !Director::is_ajax()) {
$val = "<pre style=\"font-family: Courier new\">" . htmlentities($val) . "</pre>\n";