content: treat unreplaced template placeholders as invalid links

URLs like "{unsubscribe}" parse without error in Go, so they were
reported as valid links and even counted as unsubscribe methods just
because they contain the word "unsubscribe".

Detect common un-substituted merge-field syntaxes ({x}, {{x}}, ${x},
*|X|*, %x%, [x], %7Bx%7D), mark such links invalid (Broken status),
exclude them from unsubscribe method detection, and surface them via a
new unreplaced_template content issue.
This commit is contained in:
nemunaire 2026-06-13 11:24:53 +09:00
commit f88701681f
3 changed files with 172 additions and 8 deletions

View file

@ -265,7 +265,7 @@ components:
properties:
type:
type: string
enum: [broken_html, missing_alt, excessive_images, obfuscated_url, suspicious_link, dangerous_html]
enum: [broken_html, missing_alt, excessive_images, obfuscated_url, suspicious_link, dangerous_html, unreplaced_template]
description: Type of content issue
example: "missing_alt"
severity: