diff --git a/.github/workflows/cleanup.yml b/.github/workflows/cleanup.yml index 8843ed3..9fa974f 100644 --- a/.github/workflows/cleanup.yml +++ b/.github/workflows/cleanup.yml @@ -53,10 +53,10 @@ jobs: status=$(curl -L -s -o /dev/null -w '%{http_code}' \ -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ -H "Accept: application/vnd.github+json" \ - "https://api.github.com/repos/$repo/collaborators/$user" + "https://api.github.com/repos/$repo/collaborators/$user/permission" ) echo "status $status for user $user" - if [ "$status" = "204" ]; then + if [ "$status" = "200" ]; then echo "reviewer=$user" >> $GITHUB_OUTPUT else echo "reviewer=" >> $GITHUB_OUTPUT