summaryrefslogtreecommitdiff
path: root/calendar-cli.py
diff options
context:
space:
mode:
Diffstat (limited to 'calendar-cli.py')
-rwxr-xr-xcalendar-cli.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/calendar-cli.py b/calendar-cli.py
index 98fc79d..7ad68a6 100755
--- a/calendar-cli.py
+++ b/calendar-cli.py
@@ -285,7 +285,7 @@ def calendar_agenda(caldav_conn, args):
for event_cal in events_:
for event in event_cal.instance.components():
dtstart = event.dtstart.value
- if not hasattr(dtstart, 'tzinfo') or not dtstart.tzinfo:
+ if hasattr(dtstart, 'tzinfo') and not dtstart.tzinfo:
dtstart = args.timezone.localize(dtstart)
events.append({'dtstart': dtstart, 'instance': event})
events.sort(lambda a,b: cmp(a['dtstart'], b['dtstart']))