]> git.eshelyaron.com Git - emacs.git/commitdiff
Cosmetic changes to use-package-ensure-elpa
authorJonas Bernoulli <jonas@bernoul.li>
Fri, 13 Oct 2017 12:09:13 +0000 (14:09 +0200)
committerJonas Bernoulli <jonas@bernoul.li>
Fri, 13 Oct 2017 12:09:13 +0000 (14:09 +0200)
lisp/use-package/use-package.el

index 4720c072ba66bee764550a191d9f4e8f50b7e0f2..969cd0beabfd10ca86c58f01d838b4f0799fe29e 100644 (file)
@@ -741,14 +741,15 @@ If the package is installed, its entry is removed from
               (progn
                 (when (assoc package (bound-and-true-p package-pinned-packages))
                   (package-read-all-archive-contents))
-                (if (assoc package package-archive-contents)
-                    (progn (package-install package) t)
-                  (progn
-                    (package-refresh-contents)
-                    (when (assoc package (bound-and-true-p
-                                          package-pinned-packages))
-                      (package-read-all-archive-contents))
-                    (package-install package))))
+                (cond ((assoc package package-archive-contents)
+                       (package-install package)
+                       t)
+                      (t
+                       (package-refresh-contents)
+                       (when (assoc package
+                                    (bound-and-true-p package-pinned-packages))
+                         (package-read-all-archive-contents))
+                       (package-install package))))
             (error (message "Error: Cannot load %s: %S" name err)
                    nil))))))