Edit option is now always shown on compendium actions (#423)

This commit is contained in:
WBHarry 2025-07-26 23:30:44 +02:00 committed by GitHub
parent e98adc55b7
commit 5cd9075732
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 5 additions and 4 deletions

View file

@ -305,7 +305,7 @@ export default function DHApplicationMixin(Base) {
icon: 'fa-solid fa-pen-to-square',
condition: target => {
const doc = getDocFromElementSync(target);
return doc && (!doc.hasOwnProperty('systemPath') || doc.inCollection);
return !doc || !doc.hasOwnProperty('systemPath') || doc.inCollection;
},
callback: async target => (await getDocFromElement(target)).sheet.render({ force: true })
}