racket-mode: avoid using flycheck-disable-checker

The problem is that at this point, flycheck-mode might not be active
yet. Calling flycheck-disable-checker always call (flycheck-buffer)
which would result in an error: (user-error "Flycheck mode disabled")
This commit is contained in:
Sorawee Porncharoenwase 2020-08-04 17:30:39 -07:00
parent 01c5c35686
commit 214411edb4

View file

@ -34,7 +34,8 @@
(when (featurep! :checkers syntax)
(add-hook! 'racket-xp-mode-hook
(defun +racket-disable-flycheck-h ()
(flycheck-disable-checker 'racket)))))
(unless (memq 'racket flycheck-disabled-checkers)
(push 'racket flycheck-disabled-checkers))))))
(unless (or (featurep! :editor parinfer)
(featurep! :editor lispy))