Skip to content

Commit ebb4b3b

Browse files
committed
fix: set correct header
Signed-off-by: Viet-Anh Duong <vietanhs0817@gmail.com>
1 parent 2953af9 commit ebb4b3b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hander.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ func errorHandler(t *template.Template) func(http.ResponseWriter, *http.Request)
3939
w.Header().Set(RequestId, r.Header.Get(RequestId))
4040

4141
format := r.Header.Get(ContentType)
42-
if format != "application/json" {
42+
if strings.HasPrefix(format, "application/json") {
4343
format = DefaultFormat
4444
}
4545

0 commit comments

Comments
 (0)