@makehq/forman-schema 1.9.0 → 1.9.1
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.cjs +2 -1
- package/dist/index.js +2 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -585,7 +585,8 @@ function validateFormanField(field) {
|
|
|
585
585
|
}
|
|
586
586
|
function appendQueryString(path, domain, tail) {
|
|
587
587
|
if (path.startsWith("api://")) return path;
|
|
588
|
-
const
|
|
588
|
+
const existingParams = new Set(new URL(path).searchParams.keys());
|
|
589
|
+
const queryString = tail.filter((part) => !existingParams.has(part)).map((part) => `${encodeURIComponent(part)}={{${part}}}`).join("&");
|
|
589
590
|
if (!queryString) return path;
|
|
590
591
|
const separator = path.includes("?") ? "&" : "?";
|
|
591
592
|
return `${path}${separator}${queryString}`;
|
package/dist/index.js
CHANGED
|
@@ -556,7 +556,8 @@ function validateFormanField(field) {
|
|
|
556
556
|
}
|
|
557
557
|
function appendQueryString(path, domain, tail) {
|
|
558
558
|
if (path.startsWith("api://")) return path;
|
|
559
|
-
const
|
|
559
|
+
const existingParams = new Set(new URL(path).searchParams.keys());
|
|
560
|
+
const queryString = tail.filter((part) => !existingParams.has(part)).map((part) => `${encodeURIComponent(part)}={{${part}}}`).join("&");
|
|
560
561
|
if (!queryString) return path;
|
|
561
562
|
const separator = path.includes("?") ? "&" : "?";
|
|
562
563
|
return `${path}${separator}${queryString}`;
|