mirror of
https://gitee.com/ant-design-blazor/ant-design-blazor.git
synced 2024-11-29 10:38:18 +08:00
fix(module: form): exception during validation for some nullable types (#4137)
This commit is contained in:
parent
d93817ad54
commit
eb5b19ac59
@ -20,6 +20,11 @@ namespace AntDesign.Internal.Form.Validate
|
||||
|
||||
public override bool IsValid(object value)
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
var type = value.GetType();
|
||||
var typeMinValue = GetMinValueString(type);
|
||||
|
||||
|
@ -20,6 +20,10 @@ namespace AntDesign.Internal.Form.Validate
|
||||
|
||||
public override bool IsValid(object value)
|
||||
{
|
||||
if (value == null)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
var type = value.GetType();
|
||||
var typeMaxValue = GetMaxValueString(type);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user