Closed SW-Vincent closed 1 month ago
Hi @SW-Vincent . Thank you for creating this issue. That definitely sounds like something that should be addressed. I will notify our Product team and see if we can prioritise this ticket to be worked on soon.
@SW-Vincent The fix has been merged and should be included in the next Matomo release. We decided not to make the fix retroactive. So, the issue will be fixed going forward, but any existing variables with this issue will need to be manually fixed. As it causes a JS error, chances are most that have run into this issue have already updated the broken references.
Calling Matomo Tag Manager variables within custom JavaScript variables is a quite recent (and greatly apreciated) feature.
When changing a Matomo Tag Manager variable name called within a custom JavaScript variable, its reference will not be updated. It can be a big issue, as there is no error handling within Matomo Tag Manager, and leaving an invalid reference within a variable will lead to Matomo Tag Manager to crash in case of publication (i.e. no tag will trigger anymore, even when unrelated to the said variable).
Note that this issue does not exist for calling a variable within tags (which is an older feature).