Skip to content

Commit bff9c9c

Browse files
authored
Merge pull request #4 from brightdigit/shendy/v1.0.0/fix/featuredImage/double-slash
fix: replace of // with / of feature image url path
2 parents 4983fd9 + 4347bd4 commit bff9c9c

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

Sources/ContributeWordPress/WordPressMarkdownProcessor.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,9 @@ public struct WordPressMarkdownProcessor<
9292
// From the list of images attached to this post,
9393
// choose the first one as featuredImage
9494
let featuredImagePath = assets.first { $0.parentID == post.ID }.map {
95-
["", assetRoot, $0.newPath].joined(separator: "/")
95+
["", assetRoot, $0.newPath]
96+
.joined(separator: "/")
97+
.replacingOccurrences(of: "//", with: "/")
9698
}
9799

98100
_ = try self.contentBuilder.write(

0 commit comments

Comments
 (0)