From 8ad2ee33a1107afe2d35e3ba4506d45dbb4c13d2 Mon Sep 17 00:00:00 2001 From: Artur Malabarba Date: Mon, 2 Feb 2015 13:26:40 -0200 Subject: [PATCH] emacs-lisp/package.el (package--get-deps): Fix returning duplicates. --- lisp/ChangeLog | 1 + lisp/emacs-lisp/package.el | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1c0518b6e21..382b6537af6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -4,6 +4,7 @@ function. (package-initialize): Use it to populate `package-selected-packages'. (package-menu-execute): Clean unnecessary `and'. + (package--get-deps): Fix returning duplicates. 2015-02-02 Michael Albinus diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index c4a658b3d2e..16271060626 100644 --- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el @@ -1428,9 +1428,9 @@ The file can either be a tar file or an Emacs Lisp file." when (assq name package-alist) collect name)) (indirect-deps (unless (eq only 'direct) - (apply #'append - direct-deps - (mapcar #'package--get-deps direct-deps))))) + (delete-dups + (cl-loop for p in direct-deps + append (package--get-deps p)))))) (cl-case only (direct direct-deps) (separate (list direct-deps indirect-deps)) -- 2.39.2