Skip to content

Commit

Permalink
[#1372] Prevent damage application w/o target from erroring on world …
Browse files Browse the repository at this point in the history
…load
  • Loading branch information
arbron committed Mar 21, 2024
1 parent d20e67a commit e712ccf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion module/applications/components/damage-application.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export default class DamageApplicationElement extends HTMLElement {
targetedTokens = (this.chatMessage.getFlag("dnd5e", "targets") ?? []).map(t => t.uuid);
break;
case "selected":
targetedTokens = canvas.tokens.controlled.map(t => t.actor?.uuid);
targetedTokens = canvas.tokens?.controlled?.map(t => t.actor?.uuid) ?? [];
break;
}
targetedTokens = Array.from(new Set(targetedTokens));
Expand Down

0 comments on commit e712ccf

Please sign in to comment.