pac-proxy-cli 0.1.3 → 0.1.4

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pac-proxy-cli",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "HTTP 代理与隧道 CLI + Web 管理面板",
5
5
  "type": "module",
6
6
  "files": [
@@ -18,7 +18,7 @@ export function createProxyServer(port, upstream, opts = {}) {
18
18
  }
19
19
  const url = clientReq.url || '/';
20
20
  const method = clientReq.method || 'GET';
21
- const fullUrl = `http://${targetHost}${url}`;
21
+ const fullUrl = (url.startsWith('http://') || url.startsWith('https://')) ? url : `http://${targetHost}${url}`;
22
22
 
23
23
  let captureId = null;
24
24
  if (captureStore) {