- if ( !( lastCursor = cursors[ cursors.length - 1 ] ) )\r
- return null;\r
- return new characterRange(\r
- new characterWalker(\r
- getRangeAfterCursor( lastCursor ) ),\r
- maxLength );\r
+\r
+ if ( ( lastCursor = cursors[ cursors.length - 1 ] ) )\r
+ nextRangeWalker = new characterWalker( getRangeAfterCursor( lastCursor ) );\r
+ // In case it's an empty range (no cursors), figure out next range from walker (#4951).\r
+ else\r
+ nextRangeWalker = this._.walker;\r
+\r
+ return new characterRange( nextRangeWalker, maxLength );\r