mirror of
https://gitee.com/johng/gf
synced 2026-06-06 16:21:40 +08:00
remove the space trimming of the validation value for package gvalid
This commit is contained in:
@ -123,7 +123,8 @@ func doCheck(key string, value interface{}, rules string, messages interface{},
|
||||
}
|
||||
// It converts value to string and then does the validation.
|
||||
var (
|
||||
val = strings.TrimSpace(gconv.String(value))
|
||||
// Do not trim it as the space is also part of the value.
|
||||
val = gconv.String(value)
|
||||
data = make(map[string]string)
|
||||
errorMsgs = make(map[string]string)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user