added a set of methods for undo