From 7dd2b65a5429b00f230ceec1fd0bc99f84915c45 Mon Sep 17 00:00:00 2001 From: Dmitry Sboychakov Date: Tue, 14 Sep 2021 09:52:50 +0530 Subject: [PATCH] fix: incorrect cursor movement after undo/redo shortcuts --- lib/src/widgets/controller.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/widgets/controller.dart b/lib/src/widgets/controller.dart index 7d2e0714..b3173ed2 100644 --- a/lib/src/widgets/controller.dart +++ b/lib/src/widgets/controller.dart @@ -85,7 +85,7 @@ class QuillController extends ChangeNotifier { } void _handleHistoryChange(int? len) { - if (len! > 0) { + if (len != 0) { // if (this.selection.extentOffset >= document.length) { // // cursor exceeds the length of document, position it in the end // updateSelection(