added negative number test

This commit is contained in:
Gani Georgiev committed 2023-06-26 12:42:53 +03:00
1 parent 2e8e835a68
commit edd2eaae88
2 files changed
+3 -3

No files matched your search

+1 -1
View File
@@ -118,7 +118,7 @@ func normalizeMultipartValue(raw string) any {
case "false":
return false
default:
if raw[0] >= '0' && raw[0] <= '9' {
if raw[0] == '-' || (raw[0] >= '0' && raw[0] <= '9') {
if v, err := cast.ToFloat64E(raw); err == nil {
return v
}