Skip to content
This repository has been archived by the owner on Feb 21, 2022. It is now read-only.

missing required field "name" #34

Closed
AlexanderChen1989 opened this issue Oct 21, 2021 · 1 comment
Closed

missing required field "name" #34

AlexanderChen1989 opened this issue Oct 21, 2021 · 1 comment

Comments

@AlexanderChen1989
Copy link

{"level":"error","msg":"could not create item","handler":"ItemHandler","method":"Create","error":"ent: missing required field "name""}

	var d ItemCreateRequest
	if err := easyjson.UnmarshalFromReader(r.Body, &d); err != nil {
		l.Error("error decoding json", zap.Error(err))
		BadRequest(w, "invalid json string")
		return
	}

easyjson.UnmarshalFromReader can't unmarshal from body properly

@masseelch
Copy link
Owner

Hey @AlexanderChen1989, thank you for reporting this. Can you create a minimal reproducible example for me to look at?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants