Fix refactoring bug.