- fixed a bug in the "undo", "redo" functions
