From ccbb54ce9b24cbde66393a9b59e69d625ce9181a Mon Sep 17 00:00:00 2001 From: danoctavian Date: Tue, 25 Jul 2023 17:39:46 +0300 Subject: [PATCH] fix handling of empty allowed pools list --- scripts/products/generate-setProducts-tx.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/products/generate-setProducts-tx.js b/scripts/products/generate-setProducts-tx.js index 200faccb1f..7c8f94e760 100644 --- a/scripts/products/generate-setProducts-tx.js +++ b/scripts/products/generate-setProducts-tx.js @@ -70,7 +70,7 @@ const main = async (provider, productsDataFilePath) => { capacityReductionRatio: parseInt(data['Capacity Reduction Ratio']), useFixedPrice: data['Use fixed price'].trim() === 'TRUE', }, - allowedPools: data['Allowed Pools'].split(',').map(parseInt), + allowedPools: data['Allowed Pools'].split(',').map(v => v.trim()).filter(v => v.length > 0).map(parseInt), }; return productParams;