fix switch bug
Merge pull request #16 from RickySu/master

switch bug