working on switch

looks like errors in source files