Fixed refactoring