start of refactoring
removed echo