mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-01 12:17:25 -05:00
Simplify dashboard initial buffer check
We only need to check if we're in the scratch buffer. doom-real-buffer-p is overkill for that. This also reduces file loads at startup for autoloaded functions added to the doom-real-buffer-functions and doom-unreal-buffer-functions.
This commit is contained in:
@ -207,9 +207,9 @@ project (which may be different across perspective)."
|
||||
|
||||
(defun +doom-dashboard-initial-buffer ()
|
||||
"Returns buffer to display on startup. Designed for `initial-buffer-choice'."
|
||||
(if (doom-real-buffer-p)
|
||||
(current-buffer)
|
||||
(doom-fallback-buffer)))
|
||||
(if (eq (current-buffer) (get-buffer "*scratch*"))
|
||||
(doom-fallback-buffer)
|
||||
(current-buffer)))
|
||||
|
||||
(defun +doom-dashboard-p (buffer)
|
||||
"Returns t if BUFFER is the dashboard buffer."
|
||||
|
Reference in New Issue
Block a user