Switching to using the POJ of app instead of the context

This commit is contained in:
nsalyzyn 2025-12-20 14:39:20 -07:00
parent f9aad77484
commit ffc82daeea
2 changed files with 2 additions and 2 deletions

View file

@ -197,7 +197,7 @@ Hooks.on('renderChatMessageHTML', (app, element, _) => {
enricherRenderSetup(element);
// Despite documentation, the third parameter may be empty as per
// https://github.com/foundryvtt/foundryvtt/issues/11984
const message = app._source;
const message = app.toObject(false);
const cssClass = message.flags?.daggerheart?.cssClass;
if (cssClass) cssClass.split(' ').forEach(cls => element.classList.add(cls));
});