frontpage-host 0.2.7 → 0.2.8
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/commands/shop.js +2 -2
- package/package.json +1 -1
package/dist/commands/shop.js
CHANGED
|
@@ -433,8 +433,8 @@ export async function runShop(args) {
|
|
|
433
433
|
const variantId = requireVariantId(takeFlag(work, "--id") ?? takeFlag(work, "--variant"));
|
|
434
434
|
const priceCents = parseCentsFlag(takeFlag(work, "--price-cents"), "priceCents");
|
|
435
435
|
const discountCents = parseCentsFlag(takeFlag(work, "--discount-cents"), "discountPriceCents");
|
|
436
|
-
const clearDiscount =
|
|
437
|
-
if (clearDiscount && discountCents !== undefined) {
|
|
436
|
+
const clearDiscount = takeBoolish(work, "--clear-discount", "clear-discount");
|
|
437
|
+
if (clearDiscount !== undefined && discountCents !== undefined) {
|
|
438
438
|
throw new CliHttpError("Use either --discount-cents or --clear-discount, not both.", EXIT_USAGE, 0, "bad_request");
|
|
439
439
|
}
|
|
440
440
|
const stockRaw = takeFlag(work, "--stock");
|