mcp-remote 0.1.1 → 0.1.2

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.
@@ -14,7 +14,7 @@ var require_package = __commonJS({
14
14
  "package.json"(exports, module) {
15
15
  module.exports = {
16
16
  name: "mcp-remote",
17
- version: "0.1.1",
17
+ version: "0.1.2",
18
18
  description: "Remote proxy for Model Context Protocol, allowing local-only clients to connect to remote servers using oAuth",
19
19
  keywords: [
20
20
  "mcp",
@@ -6800,8 +6800,9 @@ async function findAvailablePort(preferredPort) {
6800
6800
  }
6801
6801
  async function parseCommandLineArgs(args, defaultPort, usage) {
6802
6802
  const headers = {};
6803
- args.forEach((arg, i) => {
6804
- if (arg === "--header" && i < args.length - 1) {
6803
+ let i = 0;
6804
+ while (i < args.length) {
6805
+ if (args[i] === "--header" && i < args.length - 1) {
6805
6806
  const value = args[i + 1];
6806
6807
  const match = value.match(/^([A-Za-z0-9_-]+):(.*)$/);
6807
6808
  if (match) {
@@ -6810,8 +6811,10 @@ async function parseCommandLineArgs(args, defaultPort, usage) {
6810
6811
  log(`Warning: ignoring invalid header argument: ${value}`);
6811
6812
  }
6812
6813
  args.splice(i, 2);
6814
+ continue;
6813
6815
  }
6814
- });
6816
+ i++;
6817
+ }
6815
6818
  const serverUrl = args[0];
6816
6819
  const specifiedPort = args[1] ? parseInt(args[1]) : void 0;
6817
6820
  const allowHttp = args.includes("--allow-http");
package/dist/client.js CHANGED
@@ -11,7 +11,7 @@ import {
11
11
  log,
12
12
  parseCommandLineArgs,
13
13
  setupSignalHandlers
14
- } from "./chunk-YJSTSVFG.js";
14
+ } from "./chunk-XFJBHM5U.js";
15
15
 
16
16
  // src/client.ts
17
17
  import { EventEmitter } from "events";
package/dist/proxy.js CHANGED
@@ -9,7 +9,7 @@ import {
9
9
  mcpProxy,
10
10
  parseCommandLineArgs,
11
11
  setupSignalHandlers
12
- } from "./chunk-YJSTSVFG.js";
12
+ } from "./chunk-XFJBHM5U.js";
13
13
 
14
14
  // src/proxy.ts
15
15
  import { EventEmitter } from "events";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mcp-remote",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "Remote proxy for Model Context Protocol, allowing local-only clients to connect to remote servers using oAuth",
5
5
  "keywords": [
6
6
  "mcp",