Fixed crash when text was shorter than 4 characters