Skip to content

Commit

Permalink
Merge pull request #56 from pboos/patch-1
Browse files Browse the repository at this point in the history
Allow empty due dates
  • Loading branch information
sarumont committed Sep 19, 2014
2 parents cf7d17a + 2cfb79e commit 2371296
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion trello/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -553,7 +553,8 @@ def fetch(self, eager=True):
self.labels = json_obj['labels']
self.badges = json_obj['badges']
# For consistency, due date is in YYYY-MM-DD format
self.due = json_obj.get('due', '')[:10]
if json_obj.get('due', ''):
self.due = json_obj.get('due', '')[:10]
self.checked = json_obj['checkItemStates']
self.dateLastActivity = dateparser.parse(json_obj['dateLastActivity'])

Expand Down

0 comments on commit 2371296

Please sign in to comment.