summaryrefslogtreecommitdiff
path: root/protocols/Discord/src/http.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/Discord/src/http.cpp')
-rw-r--r--protocols/Discord/src/http.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/protocols/Discord/src/http.cpp b/protocols/Discord/src/http.cpp
index a9136c5552..e9dc031e62 100644
--- a/protocols/Discord/src/http.cpp
+++ b/protocols/Discord/src/http.cpp
@@ -59,11 +59,11 @@ AsyncHttpRequest::AsyncHttpRequest(CDiscordProto *ppro, int iRequestType, LPCSTR
}
else flags |= NLHRF_NODUMPSEND;
- AddHeader("Content-Type", "application/json");
if (pRoot != NULL) {
ptrW text(json_write(pRoot));
pData = mir_utf8encodeW(text);
dataLength = (int)mir_strlen(pData);
+ AddHeader("Content-Type", "application/json");
}
requestType = iRequestType;