Skip to content

Commit f6d4062

Browse files
bmagsyl20bnr
authored andcommitted
helm-bookmarks: don't change keys to early
helm-bookmark-map might not be available yet when helm-mode is enabled, so don't change bindings until it is available. (fixes a void-variable error)
1 parent 8e1af14 commit f6d4062

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

layers/+completion/helm/packages.el

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,6 @@
127127
(helm-locate-set-command)
128128
(setq helm-locate-fuzzy-match (string-match "locate" helm-locate-command))
129129
;; alter helm-bookmark key bindings to be simpler
130-
;; TODO check if there is a more elegant solution to setup these bindings
131130
(defun simpler-helm-bookmark-keybindings ()
132131
(define-key helm-bookmark-map (kbd "C-d") 'helm-bookmark-run-delete)
133132
(define-key helm-bookmark-map (kbd "C-e") 'helm-bookmark-run-edit)
@@ -136,7 +135,8 @@
136135
(define-key helm-bookmark-map
137136
(kbd "C-o") 'helm-bookmark-run-jump-other-window)
138137
(define-key helm-bookmark-map (kbd "C-/") 'helm-bookmark-help))
139-
(add-hook 'helm-mode-hook 'simpler-helm-bookmark-keybindings)
138+
(with-eval-after-load 'helm-bookmark
139+
(simpler-helm-bookmark-keybindings))
140140
(with-eval-after-load 'helm-mode ; required
141141
(spacemacs|hide-lighter helm-mode)))))
142142

0 commit comments

Comments
 (0)