dabo Commit
Revision 5618
Date: 2010-02-01 16:49:32 -0800 (Mon, 01 Feb 2010)
Author: Paul
Trac: http://trac.dabodev.com/changeset/5618
Changed:
U trunk/dabo/lib/reportWriter.py
Log:
Fixed a bug in the undo() function: would fail if no valid action had taken
place yet.
Diff:
Modified: trunk/dabo/lib/reportWriter.py
===================================================================
--- trunk/dabo/lib/reportWriter.py 2010-02-01 23:37:05 UTC (rev 5617)
+++ trunk/dabo/lib/reportWriter.py 2010-02-02 00:49:32 UTC (rev 5618)
@@ -969,11 +969,10 @@
self.undoLog.append(args)
def undo(self):
- try:
- obj, prop, oldval, newval = self.undoLog.pop()
- except IndexError:
+ if not self.undoLog:
print "nothing to undo"
return
+ obj, prop, oldval, newval = self.undoLog.pop()
obj.setProp(prop, oldval, logUndo=False)
def cancel(self):
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message:
http://leafe.com/archives/byMID/[email protected]