Fixed maxLength condition