fixed syntax errors on case statement