Skip to content

Commit 6785757

Browse files
committed
Fix caret jumping bug
Caret was jumping a letter when translation and recursive options are used together.
1 parent 074995e commit 6785757

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/jquery.mask.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@
309309
if (translation.recursive) {
310310
if (resetPos === -1) {
311311
resetPos = m;
312-
} else if (m === lastMaskChar) {
312+
} else if (m === lastMaskChar && m !== resetPos) {
313313
m = resetPos - offset;
314314
}
315315

0 commit comments

Comments
 (0)