Skip to content

Fails to decode struct if field is missing #21

@fogfish

Description

@fogfish

The library fails to decode a struct if field is missing.

E.g. I do have a struct

type TokenExchange struct {
  Type string `form:"grant_type"`
  Code string `form:"code"`
}

The input string to parse

grant_type=authorization_code&code=xxx&client_id=xxx

The library fails to decode string with an error

client_id doesn't exist in main.TokenExchange

I would expect that library skips client_id.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions