diff --git a/src/parser.js b/src/parser.js index a166e70..9a2b5bb 100644 --- a/src/parser.js +++ b/src/parser.js @@ -226,6 +226,10 @@ function populateFrontmatter(posts) { // inject custom taxonomy slugs into frontmatter, each taxonomy as its own field Object.entries(post.customTaxonomies).forEach(([domain, slugs]) => { if (slugs.length > 0) { + if (post.frontmatter.hasOwnProperty(domain)) { + console.warn(`⚠️ Skipping custom taxonomy '${domain}' on post '${post.slug}' because it conflicts with an existing frontmatter field.`); + return; + } post.frontmatter[domain] = slugs; } });