Skip to content

Commit

Permalink
fix(backend): handle edge case when task area contains no geometries …
Browse files Browse the repository at this point in the history
…(fmtm-splitter #28)
  • Loading branch information
spwoodcock committed Apr 19, 2024
1 parent e1bb962 commit 58ed019
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/backend/app/projects/project_crud.py
Original file line number Diff line number Diff line change
Expand Up @@ -1065,7 +1065,8 @@ async def generate_project_files(

for task in project.tasks:
# Add task feature count to task
task.feature_count = len(task_extract_dict[task.id].get("features", []))
task_features = task_extract_dict.get(task.id, {})
task.feature_count = len(task_features.get("features", []))
log.debug(f"({task.feature_count}) features added for task ({task.id})")

# Commit all updated database records
Expand Down

0 comments on commit 58ed019

Please sign in to comment.