Skip to content

Commit 21cfef2

Browse files
build(release): 1.11.6 [skip ci]
## [1.11.6](v1.11.5...v1.11.6) (2025-03-03) ### Bug Fixes * **deps:** bump the production-dependencies group with 2 updates ([#210](#210)) ([1ff1dea](1ff1dea))
1 parent 1ff1dea commit 21cfef2

File tree

3 files changed

+76
-84
lines changed

3 files changed

+76
-84
lines changed

dist/main.cjs

+42-50
Original file line numberDiff line numberDiff line change
@@ -25550,7 +25550,7 @@ var require_body2 = __commonJS({
2555025550
const crypto = require("node:crypto");
2555125551
random = (max) => crypto.randomInt(0, max);
2555225552
} catch {
25553-
random = (max) => Math.floor(Math.random(max));
25553+
random = (max) => Math.floor(Math.random() * max);
2555425554
}
2555525555
var textEncoder = new TextEncoder();
2555625556
function noop() {
@@ -28815,20 +28815,13 @@ var require_env_http_proxy_agent = __commonJS({
2881528815
"http:": 80,
2881628816
"https:": 443
2881728817
};
28818-
var experimentalWarned = false;
2881928818
var EnvHttpProxyAgent = class extends DispatcherBase {
2882028819
#noProxyValue = null;
2882128820
#noProxyEntries = null;
2882228821
#opts = null;
2882328822
constructor(opts = {}) {
2882428823
super();
2882528824
this.#opts = opts;
28826-
if (!experimentalWarned) {
28827-
experimentalWarned = true;
28828-
process.emitWarning("EnvHttpProxyAgent is experimental, expect them to change at any time.", {
28829-
code: "UNDICI-EHPA"
28830-
});
28831-
}
2883228825
const { httpProxy, httpsProxy, noProxy, ...agentOpts } = opts;
2883328826
this[kNoProxyAgent] = new Agent(agentOpts);
2883428827
const HTTP_PROXY = httpProxy ?? process.env.http_proxy ?? process.env.HTTP_PROXY;
@@ -30579,8 +30572,10 @@ var require_mock_utils2 = __commonJS({
3057930572
return data;
3058030573
} else if (typeof data === "object") {
3058130574
return JSON.stringify(data);
30582-
} else {
30575+
} else if (data) {
3058330576
return data.toString();
30577+
} else {
30578+
return "";
3058430579
}
3058530580
}
3058630581
function getMockDispatch(mockDispatches, key) {
@@ -32043,10 +32038,13 @@ var require_cache2 = __commonJS({
3204332038
if (typeof key !== "string" || typeof val !== "string") {
3204432039
throw new Error("opts.headers is not a valid header map");
3204532040
}
32046-
headers[key] = val;
32041+
headers[key.toLowerCase()] = val;
3204732042
}
3204832043
} else if (typeof opts.headers === "object") {
32049-
headers = opts.headers;
32044+
headers = {};
32045+
for (const key of Object.keys(opts.headers)) {
32046+
headers[key.toLowerCase()] = opts.headers[key];
32047+
}
3205032048
} else {
3205132049
throw new Error("opts.headers is not an object");
3205232050
}
@@ -32201,17 +32199,13 @@ var require_cache2 = __commonJS({
3220132199
return headers;
3220232200
}
3220332201
const output = (
32204-
/** @type {Record<string, string | string[]>} */
32202+
/** @type {Record<string, string | string[] | null>} */
3220532203
{}
3220632204
);
3220732205
const varyingHeaders = typeof varyHeader === "string" ? varyHeader.split(",") : varyHeader;
3220832206
for (const header of varyingHeaders) {
3220932207
const trimmedHeader = header.trim().toLowerCase();
32210-
if (headers[trimmedHeader]) {
32211-
output[trimmedHeader] = headers[trimmedHeader];
32212-
} else {
32213-
return void 0;
32214-
}
32208+
output[trimmedHeader] = headers[trimmedHeader] ?? null;
3221532209
}
3221632210
return output;
3221732211
}
@@ -32793,7 +32787,12 @@ var require_memory_cache_store = __commonJS({
3279332787
assertCacheKey(key);
3279432788
const topLevelKey = `${key.origin}:${key.path}`;
3279532789
const now = Date.now();
32796-
const entry = this.#entries.get(topLevelKey)?.find((entry2) => entry2.deleteAt > now && entry2.method === key.method && (entry2.vary == null || Object.keys(entry2.vary).every((headerName) => entry2.vary[headerName] === key.headers?.[headerName])));
32790+
const entry = this.#entries.get(topLevelKey)?.find((entry2) => entry2.deleteAt > now && entry2.method === key.method && (entry2.vary == null || Object.keys(entry2.vary).every((headerName) => {
32791+
if (entry2.vary[headerName] === null) {
32792+
return key.headers[headerName] === void 0;
32793+
}
32794+
return entry2.vary[headerName] === key.headers[headerName];
32795+
})));
3279732796
return entry == null ? void 0 : {
3279832797
statusMessage: entry.statusMessage,
3279932798
statusCode: entry.statusCode,
@@ -33379,7 +33378,7 @@ var require_sqlite_cache_store = __commonJS({
3337933378
assertCacheKey(key);
3338033379
const value = this.#findValue(key);
3338133380
return value ? {
33382-
body: value.body ? Buffer.from(value.body.buffer) : void 0,
33381+
body: value.body ? Buffer.from(value.body.buffer, value.body.byteOffset, value.body.byteLength) : void 0,
3338333382
statusCode: value.statusCode,
3338433383
statusMessage: value.statusMessage,
3338533384
headers: value.headers ? JSON.parse(value.headers) : void 0,
@@ -33524,9 +33523,6 @@ var require_sqlite_cache_store = __commonJS({
3352433523
}
3352533524
let matches = true;
3352633525
if (value.vary) {
33527-
if (!headers) {
33528-
return void 0;
33529-
}
3353033526
const vary = JSON.parse(value.vary);
3353133527
for (const header in vary) {
3353233528
if (!headerValueEquals(headers[header], vary[header])) {
@@ -33543,16 +33539,17 @@ var require_sqlite_cache_store = __commonJS({
3354333539
}
3354433540
};
3354533541
function headerValueEquals(lhs, rhs) {
33542+
if (lhs == null && rhs == null) {
33543+
return true;
33544+
}
33545+
if (lhs == null && rhs != null || lhs != null && rhs == null) {
33546+
return false;
33547+
}
3354633548
if (Array.isArray(lhs) && Array.isArray(rhs)) {
3354733549
if (lhs.length !== rhs.length) {
3354833550
return false;
3354933551
}
33550-
for (let i = 0; i < lhs.length; i++) {
33551-
if (rhs.includes(lhs[i])) {
33552-
return false;
33553-
}
33554-
}
33555-
return true;
33552+
return lhs.every((x, i) => x === rhs[i]);
3355633553
}
3355733554
return lhs === rhs;
3355833555
}
@@ -34518,6 +34515,12 @@ var require_request4 = __commonJS({
3451834515
signal.removeEventListener("abort", abort);
3451934516
});
3452034517
var dependentControllerMap = /* @__PURE__ */ new WeakMap();
34518+
var abortSignalHasEventHandlerLeakWarning;
34519+
try {
34520+
abortSignalHasEventHandlerLeakWarning = getMaxListeners(new AbortController().signal) > 0;
34521+
} catch {
34522+
abortSignalHasEventHandlerLeakWarning = false;
34523+
}
3452134524
function buildAbort(acRef) {
3452234525
return abort;
3452334526
function abort() {
@@ -34745,11 +34748,8 @@ var require_request4 = __commonJS({
3474534748
this[kAbortController] = ac;
3474634749
const acRef = new WeakRef(ac);
3474734750
const abort = buildAbort(acRef);
34748-
try {
34749-
if (typeof getMaxListeners === "function" && getMaxListeners(signal) === defaultMaxListeners) {
34750-
setMaxListeners(1500, signal);
34751-
}
34752-
} catch {
34751+
if (abortSignalHasEventHandlerLeakWarning && getMaxListeners(signal) === defaultMaxListeners) {
34752+
setMaxListeners(1500, signal);
3475334753
}
3475434754
util.addAbortListener(signal, abort);
3475534755
requestFinalizer.register(ac, { signal, abort }, abort);
@@ -40739,8 +40739,7 @@ async function oauthRequest(request2, route, parameters) {
4073940739
return response;
4074040740
}
4074140741
async function exchangeWebFlowCode(options) {
40742-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40743-
request;
40742+
const request2 = options.request || request;
4074440743
const response = await oauthRequest(
4074540744
request2,
4074640745
"POST /login/oauth/access_token",
@@ -40777,8 +40776,7 @@ function toTimestamp(apiTimeInMs, expirationInSeconds) {
4077740776
return new Date(apiTimeInMs + expirationInSeconds * 1e3).toISOString();
4077840777
}
4077940778
async function createDeviceCode(options) {
40780-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40781-
request;
40779+
const request2 = options.request || request;
4078240780
const parameters = {
4078340781
client_id: options.clientId
4078440782
};
@@ -40788,8 +40786,7 @@ async function createDeviceCode(options) {
4078840786
return oauthRequest(request2, "POST /login/device/code", parameters);
4078940787
}
4079040788
async function exchangeDeviceCode(options) {
40791-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40792-
request;
40789+
const request2 = options.request || request;
4079340790
const response = await oauthRequest(
4079440791
request2,
4079540792
"POST /login/oauth/access_token",
@@ -40827,8 +40824,7 @@ function toTimestamp2(apiTimeInMs, expirationInSeconds) {
4082740824
return new Date(apiTimeInMs + expirationInSeconds * 1e3).toISOString();
4082840825
}
4082940826
async function checkToken(options) {
40830-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40831-
request;
40827+
const request2 = options.request || request;
4083240828
const response = await request2("POST /applications/{client_id}/token", {
4083340829
headers: {
4083440830
authorization: `basic ${btoa(
@@ -40853,8 +40849,7 @@ async function checkToken(options) {
4085340849
return { ...response, authentication };
4085440850
}
4085540851
async function refreshToken(options) {
40856-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40857-
request;
40852+
const request2 = options.request || request;
4085840853
const response = await oauthRequest(
4085940854
request2,
4086040855
"POST /login/oauth/access_token",
@@ -40884,8 +40879,7 @@ function toTimestamp3(apiTimeInMs, expirationInSeconds) {
4088440879
return new Date(apiTimeInMs + expirationInSeconds * 1e3).toISOString();
4088540880
}
4088640881
async function resetToken(options) {
40887-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40888-
request;
40882+
const request2 = options.request || request;
4088940883
const auth5 = btoa(`${options.clientId}:${options.clientSecret}`);
4089040884
const response = await request2(
4089140885
"PATCH /applications/{client_id}/token",
@@ -40912,8 +40906,7 @@ async function resetToken(options) {
4091240906
return { ...response, authentication };
4091340907
}
4091440908
async function deleteToken(options) {
40915-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40916-
request;
40909+
const request2 = options.request || request;
4091740910
const auth5 = btoa(`${options.clientId}:${options.clientSecret}`);
4091840911
return request2(
4091940912
"DELETE /applications/{client_id}/token",
@@ -40927,8 +40920,7 @@ async function deleteToken(options) {
4092740920
);
4092840921
}
4092940922
async function deleteAuthorization(options) {
40930-
const request2 = options.request || /* istanbul ignore next: we always pass a custom request in tests */
40931-
request;
40923+
const request2 = options.request || request;
4093240924
const auth5 = btoa(`${options.clientId}:${options.clientSecret}`);
4093340925
return request2(
4093440926
"DELETE /applications/{client_id}/grant",
@@ -41962,7 +41954,7 @@ async function sendRequestWithRetries(state, request2, options, createdAt, retri
4196241954
return sendRequestWithRetries(state, request2, options, createdAt, retries);
4196341955
}
4196441956
}
41965-
var VERSION6 = "7.1.4";
41957+
var VERSION6 = "7.1.5";
4196641958
function createAppAuth(options) {
4196741959
if (!options.appId) {
4196841960
throw new Error("[@octokit/auth-app] appId option is required");

0 commit comments

Comments
 (0)