added undo switch/feature