feed-common 1.50.2 → 1.50.3
Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
## [1.50.3](https://github.com/advertikon/package-maxify-feed-common/compare/v1.50.2...v1.50.3) (2024-10-05)
|
2
|
+
|
3
|
+
|
4
|
+
### Bug Fixes
|
5
|
+
|
6
|
+
* field parsing funcitons ([0520ed9](https://github.com/advertikon/package-maxify-feed-common/commit/0520ed9fa671b2f2ae00f3e8e97e023756a129c5))
|
7
|
+
|
1
8
|
## [1.50.2](https://github.com/advertikon/package-maxify-feed-common/compare/v1.50.1...v1.50.2) (2024-10-04)
|
2
9
|
|
3
10
|
|
@@ -296,7 +296,7 @@ export function parsePriceString({ price, min = 0, max = 1000000 }) {
|
|
296
296
|
}
|
297
297
|
else if (!Number.isFinite(match.groups?.value) ||
|
298
298
|
Number(match.groups?.value) < min ||
|
299
|
-
Number(match.groups?.value)
|
299
|
+
Number(match.groups?.value) > max) {
|
300
300
|
throw new Error(`Value should be between ${min} and ${max}`);
|
301
301
|
}
|
302
302
|
else if (!currencySchema.safeParse(match.groups?.currency).success) {
|
@@ -312,7 +312,7 @@ export function parseDimensionString({ dimension, min = 0, max = 1000000 }) {
|
|
312
312
|
}
|
313
313
|
else if (!Number.isFinite(match.groups?.value) ||
|
314
314
|
Number(match.groups?.value) < min ||
|
315
|
-
Number(match.groups?.value)
|
315
|
+
Number(match.groups?.value) > max) {
|
316
316
|
throw new Error(`Value should be between ${min} and ${max}`);
|
317
317
|
}
|
318
318
|
return { value: match.groups?.value, unit: match.groups?.unit };
|
package/package.json
CHANGED
@@ -325,7 +325,7 @@ export function parsePriceString({ price, min = 0, max = 1000000 }: { price: str
|
|
325
325
|
} else if (
|
326
326
|
!Number.isFinite(match.groups?.value) ||
|
327
327
|
Number(match.groups?.value) < min ||
|
328
|
-
Number(match.groups?.value)
|
328
|
+
Number(match.groups?.value) > max
|
329
329
|
) {
|
330
330
|
|
331
331
|
throw new Error(`Value should be between ${min} and ${max}`)
|
@@ -350,7 +350,7 @@ export function parseDimensionString({ dimension, min = 0, max = 1000000 }: { di
|
|
350
350
|
} else if (
|
351
351
|
!Number.isFinite(match.groups?.value) ||
|
352
352
|
Number(match.groups?.value) < min ||
|
353
|
-
Number(match.groups?.value)
|
353
|
+
Number(match.groups?.value) > max
|
354
354
|
) {
|
355
355
|
throw new Error(`Value should be between ${min} and ${max}`);
|
356
356
|
}
|