Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

Commit a6dcfa7

Browse files
committed
Fix update skus
1 parent c35b732 commit a6dcfa7

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

repo/listing.go

+12
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,18 @@ func UpdateListing(r []byte, isTestnet bool, dstore *Datastore, repoPath string)
185185
if err != nil {
186186
return Listing{}, err
187187
}
188+
skus := ld.Item.Skus
189+
for _, sku := range skus {
190+
if sku.BigSurcharge == "" {
191+
sku.BigSurcharge = "0"
192+
}
193+
if sku.BigQuantity == "" {
194+
sku.BigQuantity = "0"
195+
}
196+
}
197+
198+
ld.Item.Skus = skus
199+
188200
slug := ld.Slug
189201
exists, err := listingExists(slug, repoPath, isTestnet)
190202
if err != nil {

0 commit comments

Comments
 (0)