Output json object as text for debug

This commit is contained in:
Layla 2020-08-21 01:07:24 -04:00
parent 49b2dbe4c7
commit 8d1b95060a
No known key found for this signature in database
GPG Key ID: A494D9357BA1BE31

View File

@ -24,6 +24,9 @@ type PlayerPosResponse struct {
func (p *PlayerEntity) ParsePositionRequest(data []byte) (PlayerPosResponse, error) {
var response PlayerPosResponse
err := json.Unmarshal(data, &response)
if err != nil {
fmt.Printf("Failed to parse: %s", string(data[:]))
}
return response, err
}