diff --git a/module/data/action/baseAction.mjs b/module/data/action/baseAction.mjs index 0addc6b3..b5f95aff 100644 --- a/module/data/action/baseAction.mjs +++ b/module/data/action/baseAction.mjs @@ -274,13 +274,13 @@ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel */ static async getEffects(actor, effectParent) { if (!actor) return []; - + return Array.from(await actor.allApplicableEffects()).filter(effect => { /* Effects on weapons only ever apply for the weapon itself */ if (effect.parent.type === 'weapon') { /* Unless they're secondary - then they apply only to other primary weapons */ if (effect.parent.system.secondary) { - if (effectParent.type !== 'weapon' || effectParent.system.secondary) return false; + if (effectParent?.type !== 'weapon' || effectParent?.system.secondary) return false; } else if (effectParent?.id !== effect.parent.id) return false; } diff --git a/system.json b/system.json index 50b4cd2d..50a9c83b 100644 --- a/system.json +++ b/system.json @@ -2,7 +2,7 @@ "id": "daggerheart", "title": "Daggerheart", "description": "An unofficial implementation of the Daggerheart system", - "version": "1.5.1", + "version": "1.5.2", "compatibility": { "minimum": "13.346", "verified": "13.351",