@base-web-kits/base-tools-ts 1.3.12 → 1.3.13
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
package/src/ts/url/oss/index.ts
CHANGED
|
@@ -128,9 +128,10 @@ function getOSSSegs(type: string, option?: Record<string, unknown> | number | st
|
|
|
128
128
|
|
|
129
129
|
if (typeof option === 'number' || typeof option === 'string') return `${type},${option}`;
|
|
130
130
|
|
|
131
|
-
const segs = Object.entries(option)
|
|
132
|
-
.
|
|
133
|
-
.
|
|
131
|
+
const segs = Object.entries(option)
|
|
132
|
+
.filter(([, v]) => v !== null && v !== undefined)
|
|
133
|
+
.map(([k, v]) => `${k}_${v}`)
|
|
134
|
+
.join(',');
|
|
134
135
|
|
|
135
136
|
return segs ? `${type},${segs}` : '';
|
|
136
137
|
}
|