Fallback to buffer name if doom-modeline-buffer-file-name is nil.

This commit is contained in:
Vincent Zhang 2018-11-14 23:03:44 +08:00
parent ef1ee6357c
commit 15a0a8a962

View file

@ -656,7 +656,8 @@ directory, the file name, and its state (modified, read-only or non-existent)."
:face 'doom-modeline-warning :face 'doom-modeline-warning
:v-adjust -0.05) :v-adjust -0.05)
" "))) " ")))
(if (and buffer-file-name (if (and doom-modeline-buffer-file-name
buffer-file-name
(file-exists-p buffer-file-name)) (file-exists-p buffer-file-name))
doom-modeline-buffer-file-name doom-modeline-buffer-file-name
"%b"))) "%b")))