From e993a47655314865cbbbc64717416fd9122f9389 Mon Sep 17 00:00:00 2001 From: Jen-Chieh Date: Wed, 25 Nov 2020 10:50:56 +0800 Subject: [PATCH] Minor organization for init info. --- dashboard-widgets.el | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/dashboard-widgets.el b/dashboard-widgets.el index e2fa84bc..0adef402 100644 --- a/dashboard-widgets.el +++ b/dashboard-widgets.el @@ -159,13 +159,13 @@ Example: (defcustom dashboard-init-info (let ((package-count 0) (time (emacs-init-time))) - (when (boundp 'straight--profile-cache) - (setq package-count (hash-table-size straight--profile-cache))) (when (bound-and-true-p package-alist) - (setq package-count (+ (length package-activated-list) package-count))) - (if (null (zerop package-count)) - (format "%d packages loaded in %s" package-count time) - (format "Emacs started in %s" time))) + (setq package-count (length package-activated-list))) + (when (boundp 'straight--profile-cache) + (setq package-count (+ (hash-table-size straight--profile-cache) package-count))) + (if (zerop package-count) + (format "Emacs started in %s" time) + (format "%d packages loaded in %s" package-count time))) "Init info with packages loaded and init time." :type 'boolean :group 'dashboard)