Strings also should be allowed to respect allownull
This commit is contained in:
1 parent
3921c176ce
commit
8ed62a378f
2 files changed
+2
-2
No files matched your search
@@ -13969,7 +13969,7 @@ namespace DynamORM
|
|||||||
|
|
||||||
Column = attr;
|
Column = attr;
|
||||||
|
|
||||||
if (attr != null && attr.AllowNull && !Type.IsNullableType())
|
if (attr != null && attr.AllowNull && !Type.IsNullableType() && Type != typeof(string))
|
||||||
attr.AllowNull = false;
|
attr.AllowNull = false;
|
||||||
|
|
||||||
if (property.CanRead)
|
if (property.CanRead)
|
||||||
|
|||||||
@@ -111,7 +111,7 @@ namespace DynamORM.Mapper
|
|||||||
|
|
||||||
Column = attr;
|
Column = attr;
|
||||||
|
|
||||||
if (attr != null && attr.AllowNull && !Type.IsNullableType())
|
if (attr != null && attr.AllowNull && !Type.IsNullableType() && Type != typeof(string))
|
||||||
attr.AllowNull = false;
|
attr.AllowNull = false;
|
||||||
|
|
||||||
if (property.CanRead)
|
if (property.CanRead)
|
||||||
|
|||||||
Reference in new issue
Block a user