Refactoring for simplification