Fixes U4-1904 / U4-1905

This commit is contained in:
Brian Powell
2013-03-25 10:39:35 -01:00
parent ab40822a98
commit 3ea9963166

View File

@@ -468,6 +468,9 @@ namespace Umbraco.Core.Persistence.Querying
if(fieldType == typeof(DateTime))
return "'" + EscapeParam(((DateTime)value).ToString(CultureInfo.InvariantCulture)) + "'";
if (fieldType == typeof(bool))
return ((bool)value) ? Convert.ToString(1, CultureInfo.InvariantCulture) : Convert.ToString(0, CultureInfo.InvariantCulture);
return ShouldQuoteValue(fieldType)
? "'" + EscapeParam(value) + "'"
: value.ToString();