refactoring to simple