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:
parent
8c64644450
commit
08986d9101
1 changed files with 3 additions and 3 deletions
|
@ -207,9 +207,9 @@ project (which may be different across perspective)."
|
||||||
|
|
||||||
(defun +doom-dashboard-initial-buffer ()
|
(defun +doom-dashboard-initial-buffer ()
|
||||||
"Returns buffer to display on startup. Designed for `initial-buffer-choice'."
|
"Returns buffer to display on startup. Designed for `initial-buffer-choice'."
|
||||||
(if (doom-real-buffer-p)
|
(if (eq (current-buffer) (get-buffer "*scratch*"))
|
||||||
(current-buffer)
|
(doom-fallback-buffer)
|
||||||
(doom-fallback-buffer)))
|
(current-buffer)))
|
||||||
|
|
||||||
(defun +doom-dashboard-p (buffer)
|
(defun +doom-dashboard-p (buffer)
|
||||||
"Returns t if BUFFER is the dashboard buffer."
|
"Returns t if BUFFER is the dashboard buffer."
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue