diff --git a/sweepai/api.py b/sweepai/api.py index 3a0af0024a..b55b82e0ba 100644 --- a/sweepai/api.py +++ b/sweepai/api.py @@ -441,7 +441,6 @@ async def webhook(raw_request: Request): logger.info(f"Handling check suite for {request.repository.full_name}") _, g = get_github_client(request.installation.id) repo = g.get_repo(request.repository.full_name) - if request.check_run.pull_requests and issue.labels: if request.check_run.pull_requests and issue.labels: issue = repo.get_issue(request.check_run.pull_requests[0].number) if not any(label.name == "sweep" for label in issue.labels):