monoculum / formam

a package for decode form's values into struct in Go
Apache License 2.0
190 stars 19 forks source link

panic 'array index is out of bound' #40

Closed darigaaz closed 3 years ago

darigaaz commented 3 years ago
    s := struct {
        Array [2]string
    }{}

    vals := url.Values{
        "Array[2]": []string{"10"},
    }

    dec := formam.NewDecoder(nil)
    err := dec.Decode(vals, &s)

panics with array index is out of bound