undo/redo working with adding and removing plugins