From 50dd35eec7a214f3fa27fa5cdf6222863eb1914c Mon Sep 17 00:00:00 2001 From: Nathan Borror Date: Mon, 24 Oct 2016 21:45:27 -0700 Subject: [PATCH] Error output should have lowercase attribute names (#244) Adding protobuf tags to `errorBody` to get proper lowercased output when marshaled. --- runtime/errors.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/errors.go b/runtime/errors.go index 7d7a9b22415..0d3cb3bf3ca 100644 --- a/runtime/errors.go +++ b/runtime/errors.go @@ -63,8 +63,8 @@ var ( ) type errorBody struct { - Error string `json:"error"` - Code int `json:"code"` + Error string `protobuf:"bytes,1,name=error" json:"error"` + Code int `protobuf:"bytes,2,name=code" json:"code"` } //Make this also conform to proto.Message for builtin JSONPb Marshaler