These are chat archives for gin-gonic/gin

Jan 2016
Essa Alkuwari
Jan 20 2016 10:29
hello there. I'm having trouble with gin.Context bind it gives me json: unsupported type: map[int]error

For example a struct like this :

type Ballot struct {
        Ballot_ID   int    `db:"ballot_id"`
        Decision_ID int    `db:"decision_id" binding:"required"`
        Secret      int    `db:"secret" binding:"required"`
        Name        string `db:"name" binding:"required"`
        Email       string `db:"email" binding:"required"`

Trying to var b Ballot; c.Bind(&b) always gives the mentioned error above. Defining json:"...etc" does not help

okay nevermind. I didn't know it depends on Content-Type
Victor Tran
Jan 20 2016 11:08
Hi everybody, I posted this question on stackoverflow, This question is related to Gin because when I setup a server with Gin, i got the problem too because Gin use net/http to establish the server
Can someone give a look and tell me what's wrong with my server?