I have been monkeying around for a week now trying to clean up corrupted frontmatter with scripts. It’s awful.
Global find according to a regex pattern, and replace with a value or another regex pattern. Done.
There are at least five historical requests for this. It can’t be that hard.