mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 03:31:07 +01:00
Fix broken TemplateEnricher - CONFIG.MeasuredTemplate.types has been deprecated and the error was breaking the code
This commit is contained in:
parent
ba84a75bd0
commit
f5eb746510
1 changed files with 2 additions and 1 deletions
|
|
@ -10,7 +10,8 @@ export default function DhTemplateEnricher(match, _options) {
|
|||
x => x.id.toLowerCase() === split[1] || x.short === split[1]
|
||||
)?.id
|
||||
: params.range;
|
||||
if (!(type in CONFIG.MeasuredTemplate.types) || !range) return match[0];
|
||||
|
||||
if (!(Object.values(CONFIG.DH.GENERAL.templateTypes).find(x => x === type)) || !range) return match[0];
|
||||
|
||||
const label = game.i18n.localize(`DAGGERHEART.CONFIG.TemplateTypes.${type}`);
|
||||
const rangeDisplay = Number.isNaN(Number(range)) ? game.i18n.localize(`DAGGERHEART.CONFIG.Range.${range}.name`) : range;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue