diff --git a/modules/system/config-wfrp4e.js b/modules/system/config-wfrp4e.js index 79cbe3efc..b776d802e 100644 --- a/modules/system/config-wfrp4e.js +++ b/modules/system/config-wfrp4e.js @@ -1161,7 +1161,7 @@ WFRP4E.PrepareSystemItems = function() { label : "@effect.name", trigger : "immediate", script : ` - let name = this.item.flags.wfrp4e?.fearName + let name = this.item?.flags?.wfrp4e?.fearName this.effect.updateSource({"flags.wfrp4e.dialogTitle" : (name ? game.i18n.format("EFFECT.AffectTheSourceOfFearName", {name}) : game.i18n.format("EFFECT.AffectTheSourceOfFear"))}) ` } @@ -2041,7 +2041,7 @@ WFRP4E.PrepareSystemItems = function() { label : "@effect.name", trigger : "immediate", script : ` - let name = this.item.flags.wfrp4e?.fearName + let name = this.item?.flags?.wfrp4e?.fearName this.effect.updateSource({"flags.wfrp4e.dialogTitle" : (name ? game.i18n.format("EFFECT.AffectTheSourceOfFearName", {name}) : game.i18n.format("EFFECT.AffectTheSourceOfFear"))}) ` }