This commit is contained in:
WBHarry 2025-08-05 16:34:46 +02:00 committed by GitHub
parent d80b5d158d
commit 4827b337d0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 72 additions and 39 deletions

View file

@ -40,6 +40,8 @@ export default class DhpChatMessage extends foundry.documents.ChatMessage {
elements.forEach(e => {
const uuid = e.dataset.permId,
document = fromUuidSync(uuid);
if (!document) return;
e.setAttribute('data-view-perm', document.testUserPermission(game.user, 'OBSERVER'));
e.setAttribute('data-use-perm', document.testUserPermission(game.user, 'OWNER'));
});