Undo and Redo not working correctly