@base44-preview/cli 0.2.2-pr.675.788aed1 → 0.2.2-pr.676.83d8553

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli/index.js CHANGED
@@ -255175,8 +255175,40 @@ function isExcludedHostname(hostname4, excludedHosts) {
255175
255175
  }
255176
255176
  return false;
255177
255177
  }
255178
+ var STRIPE_CLIENT_USER_AGENT_HEADER = "X-Stripe-Client-User-Agent";
255179
+ function withoutLangVersion(value) {
255180
+ if (value === null) return null;
255181
+ try {
255182
+ const parsed = JSON.parse(value);
255183
+ if (parsed === null || typeof parsed !== "object" || Array.isArray(parsed) || !("lang_version" in parsed)) {
255184
+ return null;
255185
+ }
255186
+ delete parsed.lang_version;
255187
+ return JSON.stringify(parsed);
255188
+ } catch {
255189
+ return null;
255190
+ }
255191
+ }
255192
+ function stripStripeLangVersion(input, init) {
255193
+ if (init?.headers !== void 0) {
255194
+ const headers = new Headers(init.headers);
255195
+ const value = withoutLangVersion(headers.get(STRIPE_CLIENT_USER_AGENT_HEADER));
255196
+ if (value === null) return [input, init];
255197
+ headers.set(STRIPE_CLIENT_USER_AGENT_HEADER, value);
255198
+ return [input, { ...init, headers }];
255199
+ }
255200
+ if (input instanceof Request) {
255201
+ const value = withoutLangVersion(input.headers.get(STRIPE_CLIENT_USER_AGENT_HEADER));
255202
+ if (value === null) return [input, init];
255203
+ const headers = new Headers(input.headers);
255204
+ headers.set(STRIPE_CLIENT_USER_AGENT_HEADER, value);
255205
+ return [new Request(input, { headers }), init];
255206
+ }
255207
+ return [input, init];
255208
+ }
255178
255209
  function createRequestScopedStaticEgressFetch(originalFetch, readEnvironment) {
255179
- return (input, init) => {
255210
+ return (rawInput, rawInit) => {
255211
+ const [input, init] = stripStripeLangVersion(rawInput, rawInit);
255180
255212
  const env2 = readEnvironment();
255181
255213
  const binding = env2[STATIC_EGRESS_BINDING_NAME];
255182
255214
  const enableSecret = env2[STATIC_EGRESS_ENABLED_ENV];
@@ -255336,7 +255368,6 @@ var deno2 = Object.freeze({
255336
255368
  });
255337
255369
  globalThis.Deno = deno2;
255338
255370
  globalThis.Buffer = Buffer2;
255339
- if (typeof process !== "undefined") process.version = "v22.23.4";
255340
255371
  try {
255341
255372
  new AsyncLocalStorage().enterWith(void 0);
255342
255373
  } catch {
@@ -273996,4 +274027,4 @@ export {
273996
274027
  runCLI
273997
274028
  };
273998
274029
 
273999
- //# debugId=7645CAD3637685AD64756E2164756E21
274030
+ //# debugId=128CCD738880DBAF64756E2164756E21