branch: elpa/hyperdrive commit 2b3bf323a0b1f03857bffa82bbfd43b6a754881f Author: Joseph Turner <jos...@ushin.org> Commit: Joseph Turner <jos...@ushin.org>
Change: (he/api) Always use :as 'response --- hyperdrive-lib.el | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hyperdrive-lib.el b/hyperdrive-lib.el index 763c3838d9..ada75be0ad 100644 --- a/hyperdrive-lib.el +++ b/hyperdrive-lib.el @@ -206,9 +206,14 @@ make the request." (defun he/api (method entry &rest rest) "Make hyperdrive API request by METHOD for ENTRY. -REST is passed to `h/api', which see." +REST is passed to `h/api', which see. +`:as' keyword argument of `hyperdrive-api' is always `response'. +" (declare (indent defun)) - (cl-assert (eq 'response (plist-get rest :as))) + ;; Always use :as 'response + (cl-assert (null (plist-get rest :as))) + (plist-put rest :as 'response) + (pcase-let* (((map :then) rest) (then* (lambda (response) (he//api-then entry response)