fix(choice): fix Match when field data is nil
This commit is contained in:
parent
eb85de0376
commit
33e3a97d07
1 changed files with 4 additions and 0 deletions
|
|
@ -38,6 +38,10 @@ type Choices struct {
|
|||
}
|
||||
|
||||
func (c *Choices) Match(f *Field, value string) bool {
|
||||
if f.Data == nil {
|
||||
return false
|
||||
}
|
||||
|
||||
if f.IsSlice {
|
||||
v := reflect.ValueOf(f.Data)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue