Fix bug for when cursor is at the beginning of the field