From 8df4bf9981bd17277fa7d4d018a036beb6c85edc Mon Sep 17 00:00:00 2001 From: Themis Date: Wed, 22 Nov 2023 09:43:16 +0000 Subject: [PATCH] Clearing ActiveEffect5e#label deprecation warnings --- scripts/modules/Regeneration.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/modules/Regeneration.js b/scripts/modules/Regeneration.js index 3ac02f7..96c76cd 100644 --- a/scripts/modules/Regeneration.js +++ b/scripts/modules/Regeneration.js @@ -71,11 +71,11 @@ export class Regeneration { /** before we check anything else, is regen blocked on this actor? */ const regenBlockName = HELPER.setting(MODULE.data.name, "regenBlock"); - const blockEffect = actor.effects?.find(e => e.label === regenBlockName ); + const blockEffect = actor.effects?.find(e => e.name ?? e.label === regenBlockName ); const enabledBlockEffect = !(getProperty(blockEffect ?? {}, 'disabled') ?? true); if (enabledBlockEffect) { - logger.debug(game.settings.get(MODULE.data.name, "debug"), `${NAME} | ${actor.name}'s regeneration blocked by ${blockEffect.label}`); + logger.debug(game.settings.get(MODULE.data.name, "debug"), `${NAME} | ${actor.name}'s regeneration blocked by ${blockEffect.name ?? blockEffect.label}`); return null; }