remove stringToInteger and refactor stringToPastel method