From 57af6dc0614f7694d590583eeb9c5867fbab44d2 Mon Sep 17 00:00:00 2001 From: mclemente Date: Thu, 19 May 2022 13:54:51 -0300 Subject: [PATCH] Update SystemProvider.js Fix https://github.com/mclemente/party-overview/issues/41 --- module/SystemProvider.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/module/SystemProvider.js b/module/SystemProvider.js index 00aef5b..d83f9ab 100644 --- a/module/SystemProvider.js +++ b/module/SystemProvider.js @@ -769,8 +769,9 @@ export class pf2eProvider extends SystemProvider { } getItemsValue(data) { + const coins = ["Platinum Pieces", "Gold Pieces", "Silver Pieces", "Copper Pieces"]; const currency = { pp: 0, gp: 0, sp: 0, cp: 0 }; - const items = data.items.filter((a) => a.data.data.price); + const items = data.items.filter((a) => a.data.data.price && !(coins.includes(a.data?.flags?.babele?.originalName) || coins.includes(a.name))); for (const item of items) { let value = item.data.data.price.value; for (let coin in value) {