Skip to content

Commit da333ea

Browse files
fix : make correct tag if the cluster name contain spaces
1 parent 9a55430 commit da333ea

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/renamer/doModify.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ async function updateClusterTagFrontmatter(plugin: Plugin, fileItem: RenamedItem
3030
// Update the "cluster tag" property
3131
let tagName = fileItem.newPath.split("/")[1]
3232
tagName = tagName.endsWith("-cluster") ? tagName : `${tagName}-cluster`
33+
tagName = tagName.replace(/ /g, "-")
3334
const clusterTagIndex = (frontmatter.tags as string[]).findIndex(tag => tag.contains("-cluster"));
3435
(frontmatter.tags as string[])[clusterTagIndex] = tagName
3536
});

0 commit comments

Comments
 (0)