refactoring into partials