// ParseUser decodes request body into User struct
ParseUser decodes request body into User struct
// ParseUser decodes request body into User struct
func (u *User) ParseUser(r *http.Request) error {
	if r.Body == nil {
		return errors.New("No request body")
	}
	decoder := json.NewDecoder(r.Body)
	err := decoder.Decode(u)
	return err
}
func ( u * User ) ParseUser ( r * http . Request ) error { if r . Body == nil { return errors . New ( " " ) } decoder := json . NewDecoder ( r . Body ) err := decoder . Decode ( u ) return err }
ParseUser decodes request body into User struct
ParseUser decodes request body into User struct