[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/hyperdrive ad0dba6928 26/42: Fix: (he/api) Handle synchron
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/hyperdrive ad0dba6928 26/42: Fix: (he/api) Handle synchronous case |
Date: |
Wed, 19 Jun 2024 19:00:02 -0400 (EDT) |
branch: elpa/hyperdrive
commit ad0dba6928280c1668825dd8288d9b2ef5ad55af
Author: Joseph Turner <joseph@ushin.org>
Commit: Joseph Turner <joseph@ushin.org>
Fix: (he/api) Handle synchronous case
---
hyperdrive-lib.el | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/hyperdrive-lib.el b/hyperdrive-lib.el
index 7bbb3daecf..ff8f4bf2bb 100644
--- a/hyperdrive-lib.el
+++ b/hyperdrive-lib.el
@@ -218,12 +218,14 @@ REST is passed to `h/api', which see.
(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)
- (funcall then response))))
- (plist-put rest :then then*)
- (apply #'h/api method (he/url entry) rest)))
+ (pcase-let* (((map :then) rest))
+ (when then
+ (plist-put rest :then (lambda (response)
+ (he//api-then entry response)
+ (funcall then response))))
+ (let ((response (apply #'h/api method (he/url entry) rest)))
+ (unless then (funcall 'he//api-then entry response))
+ response)))
(defun he//api-then (entry response)
"Update ENTRY's metadata according to RESPONSE.
- [nongnu] elpa/hyperdrive 79541d4aab 42/42: Merge: (he/api) Consolidate hyperdrive filling logic into callback, (continued)
- [nongnu] elpa/hyperdrive 79541d4aab 42/42: Merge: (he/api) Consolidate hyperdrive filling logic into callback, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 167373402a 07/42: Comment: Add TODO, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive c15b3ee54c 09/42: Change: Remove :as 'response from calls to he/api, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 783f73c602 10/42: Change: Remove unnecessary calls h//fill, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive bc5104f80a 12/42: Change: Remove unused functions he//write, h//write, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 633e7171f6 13/42: Change: (h/url-loader) Use he/api, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 565ba68065 14/42: Change: (h/api) Explain purpose in docstring, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 4a8915688b 15/42: Comment: Note plz.el Github issue, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 3b564cdf22 22/42: Change: (h//?fill) Rename from h//?fill-latest-version, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 631a533f70 23/42: Fix: Compilation errors, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive ad0dba6928 26/42: Fix: (he/api) Handle synchronous case,
ELPA Syncer <=
- [nongnu] elpa/hyperdrive f1bda470b4 27/42: Change: Remove unnecessary calls to h//fill, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 232e38a7ae 30/42: Change: Use new X-Drive-Version header, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive c7bd3605b1 33/42: Change: (he/api) Set ENTRY hyperdrive to persisted copy, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 66247fdfdf 38/42: Meta: Update hyper-gateway-ushin to 3.10.1: More headers, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 9a48102788 37/42: Fix: (h/url-loader) Remove :as 'response, ELPA Syncer, 2024/06/19
- [nongnu] elpa/hyperdrive 5943275a30 39/42: Fix: (he/api) Rebind modified plists, ELPA Syncer, 2024/06/19