@uipath/pm-tool 1.206.0-preview.311 → 1.206.0-preview.312

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/index.js CHANGED
@@ -3,7 +3,7 @@ import {
3
3
  Command,
4
4
  metadata2,
5
5
  registerCommands2
6
- } from "./tool-e5pbrbz2.js";
6
+ } from "./tool-mjcm1bha.js";
7
7
 
8
8
  // src/index.ts
9
9
  var program = new Command;
@@ -2082,7 +2082,7 @@ var package_default = {
2082
2082
  name: "@uipath/pm-tool",
2083
2083
  author: "UiPath",
2084
2084
  license: "SEE LICENSE IN LICENSE.txt",
2085
- version: "1.206.0-preview.311",
2085
+ version: "1.206.0-preview.312",
2086
2086
  description: "Process Mining — process apps, transformations, and data ingestion.",
2087
2087
  private: false,
2088
2088
  repository: {
@@ -10459,9 +10459,20 @@ async function uploadParts(config, bytes, parts) {
10459
10459
  await Promise.all(Array.from({ length: Math.min(MAX_CONCURRENT_UPLOADS, parts.length) }, () => worker()));
10460
10460
  return completed;
10461
10461
  }
10462
+ function isPmServiceUri(config, uri) {
10463
+ let target;
10464
+ let service;
10465
+ try {
10466
+ target = new URL(uri);
10467
+ service = new URL(`${config.baseUrl.replace(/\/+$/, "")}/${encodeURIComponent(config.organizationName)}/${encodeURIComponent(config.tenantName)}/processmining_/`);
10468
+ } catch {
10469
+ return false;
10470
+ }
10471
+ return target.origin === service.origin && target.username === "" && target.password === "" && target.pathname.startsWith(service.pathname);
10472
+ }
10462
10473
  async function uploadPart(config, part, content) {
10463
10474
  const headers = { "Content-Type": "text/csv" };
10464
- if (part.uri.startsWith(config.baseUrl)) {
10475
+ if (isPmServiceUri(config, part.uri)) {
10465
10476
  headers.Authorization = `Bearer ${config.authToken}`;
10466
10477
  }
10467
10478
  const response = await fetch(part.uri, {
@@ -11284,4 +11295,4 @@ var registerCommands2 = async (program) => {
11284
11295
 
11285
11296
  export { Command, metadata2, registerCommands2 };
11286
11297
 
11287
- //# debugId=271579DC43DE2D0E64756E2164756E21
11298
+ //# debugId=5029A12DAF016DA864756E2164756E21
package/dist/tool.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  metadata2,
3
3
  registerCommands2
4
- } from "./tool-e5pbrbz2.js";
4
+ } from "./tool-mjcm1bha.js";
5
5
  export {
6
6
  metadata2 as metadata,
7
7
  registerCommands2 as registerCommands
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@uipath/pm-tool",
3
3
  "author": "UiPath",
4
4
  "license": "SEE LICENSE IN LICENSE.txt",
5
- "version": "1.206.0-preview.311",
5
+ "version": "1.206.0-preview.312",
6
6
  "description": "Process Mining — process apps, transformations, and data ingestion.",
7
7
  "private": false,
8
8
  "repository": {
@@ -27,5 +27,5 @@
27
27
  "files": [
28
28
  "dist"
29
29
  ],
30
- "gitHead": "562a7f94aae12bb340f2b18932e8809c3d76a3e0"
30
+ "gitHead": "ee91749054ba110153977dd920a4c84761ce82cd"
31
31
  }