From 3558da17c52c14a6adb83439dc8997f666e1c370 Mon Sep 17 00:00:00 2001 From: Rupert Barrow <48629751+RupertBarrow@users.noreply.github.com> Date: Wed, 17 Jan 2024 19:50:34 +0100 Subject: [PATCH] Handle personal repos as well as organization repos This fixes #147. --- utils/wait-for-workflows/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/wait-for-workflows/action.yml b/utils/wait-for-workflows/action.yml index ecc6a4f..12c6d11 100644 --- a/utils/wait-for-workflows/action.yml +++ b/utils/wait-for-workflows/action.yml @@ -42,7 +42,7 @@ runs: // https://octokit.github.io/rest.js/v19#actions-list-workflow-runs-for-repo const WORKFLOW_RUNS_FOR_REPO_RESPONSE = await github.rest.actions.listWorkflowRunsForRepo({ - owner: context.payload.organization.login, + owner: context.payload.organization?.login || context.payload.sender?.login, repo: context.payload.repository.name, head_sha: context.payload.after || GITHUB_SHA })