Help with getting disambiguation comment for file name

There seems to be a mistake in my approach for this, I’m trying to get the disambiguation comment, if any, and append it to the Album field of a release. But if it doesn’t find one in that specific release, it uses another release comment as fallback.

$set(album,$if(%_releasecomment%,%album% [$title(%_releasecomment%)],%album%))

I’m matching the CD version but I get the Digital disambiguation comment

If it does have a disambiguation comment, then it gets the correct one

It seems like we’re starting to stray from the intended purpose of this thread (as I understand it). To help reduce the number of help requests in this thread, I’ve created a new thread specifically intended for such requests:

@Totosaurio3279, if you could post a note in the new thread including a link to the album in question on the MusicBrainz site (so we can test using the same information), we’ll try to have a look at it and see what might be causing it not to return what you’re expecting. Thanks.