summaryrefslogtreecommitdiff
path: root/vendor/github.com/go-playground/form/v4/decoder.go
diff options
context:
space:
mode:
authorLibravatar dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>2023-07-21 14:22:13 +0000
committerLibravatar GitHub <noreply@github.com>2023-07-21 14:22:13 +0000
commitd53449ccb43d757915d17b0383c62cb5403a3211 (patch)
tree0ac9a2d4245fba6cbbb1207d2d309b9264f34804 /vendor/github.com/go-playground/form/v4/decoder.go
parentBump word-wrap from 1.2.3 to 1.2.4 in /web/source (#2001) (diff)
downloadgotosocial-d53449ccb43d757915d17b0383c62cb5403a3211.tar.xz
[chore]: Bump github.com/go-playground/form/v4 from 4.2.0 to 4.2.1 (#1994)
Diffstat (limited to 'vendor/github.com/go-playground/form/v4/decoder.go')
-rw-r--r--vendor/github.com/go-playground/form/v4/decoder.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/vendor/github.com/go-playground/form/v4/decoder.go b/vendor/github.com/go-playground/form/v4/decoder.go
index e71c97794..e21242279 100644
--- a/vendor/github.com/go-playground/form/v4/decoder.go
+++ b/vendor/github.com/go-playground/form/v4/decoder.go
@@ -109,7 +109,11 @@ func (d *decoder) parseMapData() {
// no need to check for error, it will always pass
// as we have done the checking to ensure
// the value is a number ahead of time.
- ke.ivalue, _ = strconv.Atoi(ke.value)
+ var err error
+ ke.ivalue, err = strconv.Atoi(ke.value)
+ if err != nil {
+ ke.ivalue = -1
+ }
if ke.ivalue > rd.sliceLen {
rd.sliceLen = ke.ivalue