Fixed so that non attack/damage actions don't error out when used (#2098)
Some checks are pending
Project CI / build (24.x) (push) Waiting to run

This commit is contained in:
WBHarry 2026-07-22 03:44:10 +02:00 committed by GitHub
parent 7f61715adf
commit a9ac8fe148
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -429,11 +429,11 @@ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel
} }
get hasDamage() { get hasDamage() {
return this.type !== 'healing' && (Boolean(this.damage.main) || !foundry.utils.isEmpty(this.damage.resources)); return this.type !== 'healing' && (Boolean(this.damage?.main) || !foundry.utils.isEmpty(this.damage?.resources));
} }
get hasHealing() { get hasHealing() {
return this.type === 'healing' && !foundry.utils.isEmpty(this.damage.resources); return this.type === 'healing' && !foundry.utils.isEmpty(this.damage?.resources);
} }
get hasSave() { get hasSave() {