diff options
author | Tobias Brox <t@tobixen.no> | 2015-04-23 22:47:06 +0200 |
---|---|---|
committer | Tobias Brox <t@tobixen.no> | 2015-04-23 22:47:06 +0200 |
commit | 076ef83777c2a187565f9ce1555d1b778f6538c1 (patch) | |
tree | d6f88111aa88f1316cccdd81b6fdc9dd3bc3105a | |
parent | 95d257e58e069c6aa3d989db47745e1ebd4f4a59 (diff) | |
download | calendar-cli-076ef83777c2a187565f9ce1555d1b778f6538c1.zip |
bugfix
-rwxr-xr-x | calendar-cli.py | 2 |
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'])) |