From 7e77b784511929257982152c933eb99f133fff0e Mon Sep 17 00:00:00 2001 From: Maxim Lebedev Date: Mon, 15 Nov 2021 02:08:21 +0500 Subject: [PATCH] :art: Format MIME type contants --- internal/common/common.go | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/internal/common/common.go b/internal/common/common.go index ddab88b..69551bc 100644 --- a/internal/common/common.go +++ b/internal/common/common.go @@ -1,8 +1,13 @@ package common +const charsetUTF8 = "charset=UTF-8" + const ( - MIMEApplicationJSON string = "application/json" - MIMEApplicationXWWWFormUrlencoded string = "application/x-www-form-urlencoded" - MIMETextHTML string = "text/html" - MIMETextPlain string = "text/plain" + MIMEApplicationForm string = "application/x-www-form-urlencoded" + MIMEApplicationJSON string = "application/json" + MIMEApplicationJSONCharsetUTF8 string = MIMEApplicationJSON + "; " + charsetUTF8 + MIMETextHTML string = "text/html" + MIMETextHTMLCharsetUTF8 string = MIMETextHTML + "; " + charsetUTF8 + MIMETextPlain string = "text/plain" + MIMETextPlainCharsetUTF8 string = MIMETextPlain + "; " + charsetUTF8 )