From 0dd800c5b15e22553f4d65f5d1dfba847d9fb7e4 Mon Sep 17 00:00:00 2001 From: Kim Mantas Date: Fri, 26 Jan 2024 14:40:08 +0000 Subject: [PATCH] Clear subjectPath cache more aggressively. --- module/documents/token.mjs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/module/documents/token.mjs b/module/documents/token.mjs index 6bec57a871..921c9759b7 100644 --- a/module/documents/token.mjs +++ b/module/documents/token.mjs @@ -151,7 +151,9 @@ export default class TokenDocument5e extends SystemFlagsMixin(TokenDocument) { /** @inheritDoc */ _onUpdate(data, options, userId) { - if ( foundry.utils.hasProperty(data, "texture.src") ) this.#subjectPath = null; + const textureChange = foundry.utils.hasProperty(data, "texture.src"); + const tokenRingChange = foundry.utils.hasProperty(data, "flags.dnd5e.tokenRings.enabled"); + if ( textureChange || tokenRingChange ) this.#subjectPath = null; super._onUpdate(data, options, userId); }