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

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

[nongnu] elpa/hyperdrive 948b2f181f 13/49: Tidy: (hyperdrive-fill-versio


From: ELPA Syncer
Subject: [nongnu] elpa/hyperdrive 948b2f181f 13/49: Tidy: (hyperdrive-fill-version-ranges) Reduce nesting
Date: Wed, 20 Sep 2023 19:01:32 -0400 (EDT)

branch: elpa/hyperdrive
commit 948b2f181fd924e23b9f35ce917d1d85fe95f58e
Author: Joseph Turner <joseph@ushin.org>
Commit: Joseph Turner <joseph@ushin.org>

    Tidy: (hyperdrive-fill-version-ranges) Reduce nesting
---
 hyperdrive-lib.el | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/hyperdrive-lib.el b/hyperdrive-lib.el
index 66a943b5cf..5ab024e1af 100644
--- a/hyperdrive-lib.el
+++ b/hyperdrive-lib.el
@@ -818,15 +818,15 @@ with no arguments."
                                 :finally finally)))
     (cl-labels ((fill-existent (entry limit)
                   ;; For existent entries, send requests in series.
-                  (when (cl-plusp limit)
-                    ;; Don't use `hyperdrive-entry-previous' here, since it 
makes a sync request
-                    (pcase-let ((`(,range-start . ,_plist) 
(hyperdrive-entry-version-range entry)))
-                      (setf (hyperdrive-entry-version entry) (1- range-start))
-                      (when (eq 'unknown (hyperdrive-entry-exists-p entry))
-                        ;; Recurse backward through history.
-                        (fill-entry entry :limit limit)
-                        ;; Return non-nil to indicate that a request was made.
-                        t))))
+                  (setf (hyperdrive-entry-version entry)
+                        ;; Fill end of previous range.
+                        (1- (car (hyperdrive-entry-version-range entry))))
+                  (when (and (cl-plusp limit)
+                             (eq 'unknown (hyperdrive-entry-exists-p entry)))
+                    ;; Recurse backward through history.
+                    (fill-entry entry :limit limit)
+                    ;; Return non-nil to indicate that a request was made.
+                    t))
                 (fill-nonexistent (entry limit)
                   (let ((nonexistent-queue (make-plz-queue
                                             :limit hyperdrive-queue-size



reply via email to

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