Issue 64 (#67)

* fix pc sheet backend actions
This commit is contained in:
IrkTheImp 2025-05-26 13:31:54 -05:00 committed by GitHub
parent 63274d67ce
commit c306c95e6b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 17 additions and 14 deletions

View file

@ -183,7 +183,7 @@ export default class SubclassSheet extends DaggerheartSheet(ItemSheetV2) {
}
async _onDrop(event) {
event.preventDefault()
event.preventDefault();
const data = TextEditor.getDragEventData(event);
const item = await fromUuid(data.uuid);
if (!(item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.subclass.id)) return;
@ -196,7 +196,7 @@ export default class SubclassSheet extends DaggerheartSheet(ItemSheetV2) {
const path = `system.${featureField}Feature.abilities`;
const abilities = duplicate(getProperty(this.document, path)) || [];
const featureData = {name: item.name, img: item.img, uuid: item.uuid };
const featureData = { name: item.name, img: item.img, uuid: item.uuid };
abilities.push(featureData);
await this.document.update({ [path]: abilities });