hamster-applet r779 - trunk/hamster



Author: tbaugis
Date: Sun Feb 22 00:03:10 2009
New Revision: 779
URL: http://svn.gnome.org/viewvc/hamster-applet?rev=779&view=rev

Log:
caught another undefined

Modified:
   trunk/hamster/db.py

Modified: trunk/hamster/db.py
==============================================================================
--- trunk/hamster/db.py	(original)
+++ trunk/hamster/db.py	Sun Feb 22 00:03:10 2009
@@ -407,7 +407,7 @@
                 if fact_start_date == today and fact["start_time"] < now:
                     # today, present
                     f["delta"] = now -  fact["start_time"]
-                elif fact_start_date == yesterday and f["id"] == last_activity["id"]:
+                elif last_activity and fact_start_date == yesterday and f["id"] == last_activity["id"]:
                     # last fact and it is in yesterday - split it!
                     #first yesterday until midnight
                     f["end_time"] = dt.datetime.combine(today, dt.time(0,0))



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]