Don't request review for my own PRs

This commit is contained in:
Jake Howard 2019-10-13 20:22:05 +01:00
parent 71a8cc7611
commit ab1b3fee59
Signed by: jake
GPG key ID: 57AFB45680EDD477

View file

@ -32,6 +32,9 @@ def todoist_repo_prs():
existing_tasks = get_existing_tasks(project_id, todoist)
existing_task_id = get_existing_task(existing_tasks, pr)
if pr.user.login == me.login:
continue # I don't need to review my own PRs!
if pr.state == "closed" and existing_task_id:
my_review = get_my_review(me, pr)
if pr.merged and my_review and my_review.state == "APPROVED":