change switch to if else
Merge branch 'master' of https://github.com/calvinyu/WSE