emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/go-mode acec0aa 471/495: Fix Content-Type for https://play


From: ELPA Syncer
Subject: [nongnu] elpa/go-mode acec0aa 471/495: Fix Content-Type for https://play.golang.org/share
Date: Sat, 7 Aug 2021 09:06:11 -0400 (EDT)

branch: elpa/go-mode
commit acec0aa67f7349eae435d74b43d129b65148fcf7
Author: Xu Chunyang <xuchunyang56@gmail.com>
Commit: Peter Sanford <psanford@sanford.io>

    Fix Content-Type for https://play.golang.org/share
    
    The url-request-data is not urlencoded, so 
application/x-www-form-urlencoded is
    wrong. The go playground doesn't care about Content-Type, it always assumes
    plaintext in UTF-8.
    
    https: //go.googlesource.com/playground/+/refs/heads/master/share.go#45
    Closes: #321 [via git-merge-pr]
---
 go-mode.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/go-mode.el b/go-mode.el
index f63df33..58a6196 100644
--- a/go-mode.el
+++ b/go-mode.el
@@ -2019,7 +2019,7 @@ code to the Playground. You can disable the confirmation 
by setting
       (message "Upload aborted")
     (let* ((url-request-method "POST")
            (url-request-extra-headers
-            '(("Content-Type" . "application/x-www-form-urlencoded")))
+            '(("Content-Type" . "text/plain; charset=UTF-8")))
            (url-request-data
             (encode-coding-string
              (buffer-substring-no-properties start end)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]