change name of method from findType() to condition().  The function does more than find the type; it also conditions the text depending on the type.