Refactoring controller