Skip to content
This repository has been archived by the owner on Oct 20, 2021. It is now read-only.

Commit

Permalink
Minor cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
j-martin committed Nov 20, 2018
1 parent 3dd5824 commit ce58e57
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions importer.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,9 +213,7 @@ def create_story(self, task: AsanaTask, subtasks: List[AsanaTask], files) -> Uni
labels.extend([{'name': label['name']} for label in task['tags']])
labels.extend([self.build_label_from_projects(project) for project in task['projects']])
labels.extend(self.build_labels_from_custom_fields(task))
section = self.get_section(task)
if section:
labels.append(section)
labels.append(self.get_section(task))
tasks = [cleanup_dict(self.build_task(subtask)) for subtask in subtasks]
workflow_id = self.clubhouse_complete_workflow_id if task['completed'] else None
task_url = self.get_asana_url(task)
Expand All @@ -230,7 +228,7 @@ def create_story(self, task: AsanaTask, subtasks: List[AsanaTask], files) -> Uni
'story_type': self.get_story_type(task),
'description': description_template.render(**task).strip(),
'external_id': task_url,
'labels': labels,
'labels': [label for label in labels if label],
'file_ids': [file['id'] for file in files],
'follower_ids': self.get_follower_ids(task),
'name': task['name'].strip(),
Expand Down

0 comments on commit ce58e57

Please sign in to comment.