Null check metadata (#1145)

* Null check metadata

* Fix d20RollDialog action find

---------

Co-authored-by: Chris Ryan <chrisr@blackhole>
Co-authored-by: Dapoolp <elcatnet@gmail.com>
This commit is contained in:
Chris Ryan 2025-09-19 06:28:25 +10:00 committed by GitHub
parent 55586c93c8
commit f1b5c80a53
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View file

@ -16,7 +16,7 @@ export default class D20RollDialog extends HandlebarsApplicationMixin(Applicatio
this.action =
config.data.attack?._id == config.source.action
? config.data.attack
: this.item.system.actions.get(config.source.action);
: this.item.system.actionsList?.find(a => a.id === config.source.action);
}
}