Skip to content

Commit

Permalink
fixup! FIX louietan#76: handle both old and new function signatures o…
Browse files Browse the repository at this point in the history
…f `request--curl-callback'
  • Loading branch information
Sodel-the-Vociferous committed Jul 4, 2022
1 parent a6965c8 commit b543552
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion anki-editor.el
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ See https://apps.ankiweb.net/docs/manual.html#latex-conflicts.")
;; why here we manually invoke callbacks to receive the result.
(unless (request-response-done-p response)
;; (request--curl-callback "localhost" (get-buffer-process (request-response--buffer response)) "finished\n")))
(if (= 2 (func-arity (function 'request--curl-callback)))
(if (equalp '(2 . 2) (func-arity 'request--curl-callback))
;; Handle the older, stable version of 'request.el' in which
;; `request--curl-callback' has two args.
(request--curl-callback (get-buffer-process (request-response--buffer response)) "finished\n")
Expand Down

0 comments on commit b543552

Please sign in to comment.