Fixed a text entry bug