simplified refactoring step 1