Skip to content

Commit 888f4bd

Browse files
committed
add check for forward-sentence-function variable
1 parent b8e871f commit 888f4bd

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

flymake-languagetool.el

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,10 @@ A positive ARG will return end point ARG number sentence following PT."
441441
(when pt
442442
(save-excursion
443443
(goto-char pt)
444-
(funcall forward-sentence-function arg))))
444+
(funcall (or (and (boundp 'forward-sentence-function)
445+
forward-sentence-function)
446+
#'forward-sentence)
447+
arg))))
445448

446449
(defun flymake-languagetool--setup ()
447450
"Used to reset the checked state of the current buffer."

0 commit comments

Comments
 (0)