Skip to content
This repository has been archived by the owner on Oct 21, 2022. It is now read-only.

Relocated repos #151

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions paradox-github.el
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,9 @@ Leave point at the return code on the first line."
(`200 t) ;; OK, with content.
;; I'll implement redirection if anyone ever reports this.
;; For now, I haven't found a place where it's used.
((or `301 `302 `303 `304 `305 `306 `307)
(`301
(search-forward "HTTP/1.1 ") t)
((or `302 `303 `304 `305 `306 `307)
(paradox--github-report "Redirect received:\n\n" (buffer-string))
;; (message "Received a redirect reply, please file a bug report (M-x `paradox-bug-report')")
nil)
Expand Down Expand Up @@ -289,7 +291,7 @@ value."
(set-process-sentinel
(apply #'start-process "paradox-github"
(generate-new-buffer "*Paradox http*")
"curl" "-s" "-i" "-d" "" "-X" ,method ,action
"curl" "-L" "-s" "-i" "-d" "" "-X" ,method ,action
(when (stringp paradox-github-token)
(list "-u" (concat paradox-github-token ":x-oauth-basic"))))
,call-name)
Expand All @@ -298,7 +300,7 @@ value."
;; Make the request.
(condition-case nil
(apply #'call-process
"curl" nil t nil "-s" "-i" "-d" "" "-X" ,method ,action
"curl" nil t nil "-L" "-s" "-i" "-d" "" "-X" ,method ,action
(when (stringp paradox-github-token)
(list "-u" (concat paradox-github-token ":x-oauth-basic"))))
(error ,unwind-form))
Expand Down