File tree Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change 75
75
(format &optional face window buffer &rest _)
76
76
(let ((original-value (funcall original-function format face window buffer)))
77
77
(if (equal format mode-name)
78
- (let* ((major-mode (and buffer
79
- (with-current-buffer buffer major-mode)))
80
- (icon (let* ((icon (nerd-icons-icon-for-mode major-mode))
81
- (icon (if (or (null icon) (symbolp icon))
82
- (nerd-icons-faicon " nf-fa-file_o" )
83
- icon)))
84
- (if (and icon
85
- (char-displayable-p (string-to-char icon)))
86
- (concat icon " " )
87
- " " ))))
78
+ (let ((icon (let* ((icon (nerd-icons-icon-for-buffer))
79
+ (icon (if (or (null icon) (symbolp icon))
80
+ (nerd-icons-faicon " nf-fa-file_o" )
81
+ icon)))
82
+ (if (and icon
83
+ (char-displayable-p (string-to-char icon)))
84
+ (concat icon " " )
85
+ " " ))))
88
86
(concat icon original-value))
89
87
original-value))))
90
88
(apply func args)))))
You can’t perform that action at this time.
0 commit comments