fixed switch case handling