Refactoring switch
Refactoring switch