Skip to content

Commit

Permalink
Fix eventdisplay teardown
Browse files Browse the repository at this point in the history
  • Loading branch information
untitaker committed Feb 16, 2015
1 parent 3ad63d6 commit 078b89f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions khal/ui/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -558,10 +558,9 @@ def teardown(data):

def destroy(self):
"""if an event is displayed, remove it"""
if (len(self.container.contents) > 2 and
isinstance(self.container.contents[2][0], EventDisplay)):
self.container.contents.pop()
while len(self.container.contents) > 1:
self.container.contents.pop()
self.current_event = None

def new(self, date):
"""create a new event on date
Expand Down

0 comments on commit 078b89f

Please sign in to comment.