Skip to content

Commit

Permalink
update validators with custom changes in IsInt function
Browse files Browse the repository at this point in the history
  • Loading branch information
Aashutosh committed Jan 16, 2024
1 parent 886e215 commit 73b5e2a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions validators.go
Original file line number Diff line number Diff line change
Expand Up @@ -614,8 +614,8 @@ func IsInt(val any, minAndMax ...int64) (ok bool) {
if val == nil {
return false
}

intVal, err := valueToInt64(val, true)
// Customization: Replace strict value:true -> false; to validate float32, float64 and string type of data. As it always gave error(i.e. false) in parsing time.
intVal, err := valueToInt64(val, false)
if err != nil {
return false
}
Expand Down

0 comments on commit 73b5e2a

Please sign in to comment.