Fixing nullable fields storage

--HG--
branch : 1.x
This commit is contained in:
Sebastien Ros
2011-11-08 15:51:39 -08:00
parent 8abcc2fdbe
commit 62aa36c5de
2 changed files with 2 additions and 2 deletions
@@ -20,7 +20,7 @@ namespace Orchard.ContentManagement.FieldStorage {
var t = typeof (T);
// the T is nullable, convert using underlying type
if(t.GetGenericTypeDefinition() == typeof(Nullable<>)) {
if (t.IsGenericType && t.GetGenericTypeDefinition() == typeof(Nullable<>)) {
t = Nullable.GetUnderlyingType(t);
}