cli/packages: fix commit between pins counting

the commit counting introduced in a3df5bf prints `nil` instead of the
empty string when the repo moves from commit A to commit B where A isn't
reachable from B
This commit is contained in:
Itai Y. Efrat 2021-06-04 15:02:00 +03:00
parent f408016c6f
commit 46c89d350e

View file

@ -447,7 +447,8 @@ declaration) or dependency thereof that hasn't already been."
(doom--abbrev-commit ref) (doom--abbrev-commit ref)
(doom--abbrev-commit target-ref) (doom--abbrev-commit target-ref)
(if (and (integerp commits) (> commits 0)) (if (and (integerp commits) (> commits 0))
(format " [%d commit(s)]" commits))) (format " [%d commit(s)]" commits)
""))
(unless (string-empty-p output) (unless (string-empty-p output)
(let ((lines (split-string output "\n"))) (let ((lines (split-string output "\n")))
(setq output (setq output