Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix noenc error by fixing Details error field #557

Merged
merged 1 commit into from
Feb 24, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions runtime/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ var (
)

type errorBody struct {
Error string `protobuf:"bytes,1,name=error" json:"error"`
Code int32 `protobuf:"varint,2,name=code" json:"code"`
Details []any.Any `protobuf:"bytes,3,name=details" json:"details"`
Error string `protobuf:"bytes,1,name=error" json:"error"`
Code int32 `protobuf:"varint,2,name=code" json:"code"`
Details []*any.Any `protobuf:"bytes,3,rep,name=details" json:"details,omitempty"`
}

// Make this also conform to proto.Message for builtin JSONPb Marshaler
Expand Down Expand Up @@ -103,7 +103,7 @@ func DefaultHTTPError(ctx context.Context, mux *ServeMux, marshaler Marshaler, w
if err != nil {
grpclog.Printf("Failed to marshal any: %v", err)
} else {
body.Details = append(body.Details, *a)
body.Details = append(body.Details, a)
}
}
}
Expand Down