Skip to content

Commit

Permalink
update: replacingOccurrences of // with /
Browse files Browse the repository at this point in the history
  • Loading branch information
devahmedshendy committed Jul 27, 2023
1 parent 4983fd9 commit 4347bd4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Sources/ContributeWordPress/WordPressMarkdownProcessor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,9 @@ public struct WordPressMarkdownProcessor<
// From the list of images attached to this post,
// choose the first one as featuredImage
let featuredImagePath = assets.first { $0.parentID == post.ID }.map {
["", assetRoot, $0.newPath].joined(separator: "/")
["", assetRoot, $0.newPath]
.joined(separator: "/")
.replacingOccurrences(of: "//", with: "/")
}

_ = try self.contentBuilder.write(
Expand Down

0 comments on commit 4347bd4

Please sign in to comment.