Refactoring phase1 finished.