Fixes an issue with empty string conversions to date time - should fail

This commit is contained in:
Shannon
2013-11-01 18:06:58 +11:00
parent 49d5791825
commit 76bc312842

View File

@@ -198,7 +198,7 @@ namespace Umbraco.Core
if (destinationType == typeof(Boolean))
return Attempt<object>.Succeed(false); // special case for booleans, null/empty == false
else if (destinationType == typeof(DateTime))
return Attempt<object>.Succeed(DateTime.MinValue);
return Attempt<object>.Succeed(false);
}
// we have a non-empty string, look for type conversions in the expected order of frequency of use...