guix-commits
[Top][All Lists]
Advanced

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

01/06: substitute: Remove unneeded conditionals.


From: Ludovic Courtès
Subject: 01/06: substitute: Remove unneeded conditionals.
Date: Mon, 13 Jul 2015 17:29:26 +0000

civodul pushed a commit to branch master
in repository guix.

commit e4e099feca0d6725b6614c2acdbae7f1dab261fb
Author: Ludovic Courtès <address@hidden>
Date:   Mon Jul 13 11:35:56 2015 +0200

    substitute: Remove unneeded conditionals.
    
    * guix/scripts/substitute.scm (guix-substitute): Remove unneeded (if cache
      ...) forms since CACHE is always true (it's a promise.)
---
 guix/scripts/substitute.scm |    8 ++------
 1 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/guix/scripts/substitute.scm b/guix/scripts/substitute.scm
index 0baba91..54491b9 100755
--- a/guix/scripts/substitute.scm
+++ b/guix/scripts/substitute.scm
@@ -800,9 +800,7 @@ substituter disabled~%")
                     (("have" paths ..1)
                      ;; Return the subset of PATHS available in CACHE.
                      (let ((substitutable
-                            (if cache
-                                (lookup-narinfos cache paths)
-                                '())))
+                            (lookup-narinfos cache paths)))
                        (for-each (lambda (narinfo)
                                    (format #t "~a~%" (narinfo-path narinfo)))
                                  (filter valid? substitutable))
@@ -810,9 +808,7 @@ substituter disabled~%")
                     (("info" paths ..1)
                      ;; Reply info about PATHS if it's in CACHE.
                      (let ((substitutable
-                            (if cache
-                                (lookup-narinfos cache paths)
-                                '())))
+                            (lookup-narinfos cache paths)))
                        (for-each (lambda (narinfo)
                                    (format #t "~a\n~a\n~a\n"
                                            (narinfo-path narinfo)



reply via email to

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