Skip to content

Commit

Permalink
Update dependencies and fix headers in httpRedirectFetch() function
Browse files Browse the repository at this point in the history
  • Loading branch information
austenstone committed Feb 22, 2024
1 parent 87f3fc8 commit bf5b69f
Show file tree
Hide file tree
Showing 4 changed files with 173 additions and 170 deletions.
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,5 +70,5 @@ outputs:
description: The number of deployed seats

runs:
using: "node16"
using: "node20"
main: "dist/index.js"
31 changes: 17 additions & 14 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30496,6 +30496,9 @@ function httpRedirectFetch (fetchParams, response) {
// https://fetch.spec.whatwg.org/#cors-non-wildcard-request-header-name
request.headersList.delete('authorization')

// https://fetch.spec.whatwg.org/#authentication-entries
request.headersList.delete('proxy-authorization', true)

// "Cookie" and "Host" are forbidden request-headers, which undici doesn't implement.
request.headersList.delete('cookie')
request.headersList.delete('host')
Expand Down Expand Up @@ -41547,20 +41550,20 @@ const run = () => __awaiter(void 0, void 0, void 0, function* () {
if (input.enterprise && input.enterprise !== null) {
core.info(`Fetching all organizations for ${input.enterprise}...`);
do {
const query = `
query ($enterprise: String!, $after: String) {
enterprise(slug: $enterprise) {
organizations(first: 100, after: $after) {
pageInfo {
endCursor
hasNextPage
}
nodes {
login
}
}
}
}
const query = `
query ($enterprise: String!, $after: String) {
enterprise(slug: $enterprise) {
organizations(first: 100, after: $after) {
pageInfo {
endCursor
hasNextPage
}
nodes {
login
}
}
}
}
`;
const variables = { "enterprise": input.enterprise, "after": afterCursor };
const response = yield octokit.graphql(query, variables);
Expand Down
Loading

0 comments on commit bf5b69f

Please sign in to comment.