From 19bb0798c8f5533a82e5cb8d892bfca1ac32de00 Mon Sep 17 00:00:00 2001 From: sladecraven Date: Thu, 7 Jul 2022 13:33:31 +0200 Subject: [PATCH] Sync --- module/actor/actor.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/module/actor/actor.js b/module/actor/actor.js index dde119c..079f886 100644 --- a/module/actor/actor.js +++ b/module/actor/actor.js @@ -203,10 +203,10 @@ export class BoLActor extends Actor { return Object.values(this.system.resources) } get boons() { - return this.items.filter(i => i.type === "feature" && i.system.subtype === "boon"); + return duplicate(this.items.filter(i => i.type === "feature" && i.system.subtype === "boon") || []); } get flaws() { - return this.items.filter(i => i.type === "feature" && i.system.subtype === "flaw"); + return duplicate(this.items.filter(i => i.type === "feature" && i.system.subtype === "flaw") || []); } get careers() { return duplicate( this.items.filter(i => i.type === "feature" && i.system.subtype === "career") || []) @@ -288,10 +288,11 @@ export class BoLActor extends Actor { } get bonusBoons() { - return this.items.filter(i => i.type === "feature" && i.system.subtype === "boon" && i.system.properties.isbonusdice); + let boons = this.items.filter(i => i.type === "feature" && i.system.subtype === "boon" && i.system.properties.isbonusdice) + return duplicate( boons || []) } get malusFlaws() { - return this.items.filter(i => i.type === "feature" && i.system.subtype === "flaw" && i.system.properties.ismalusdice); + return duplicate( this.items.filter(i => i.type === "feature" && i.system.subtype === "flaw" && i.system.properties.ismalusdice) || []); } isSorcerer() {