added an else clause to case statement