Fixed refactor