File tree 1 file changed +4
-6
lines changed
FSNotesCore/Shared/Extensions
1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -44,14 +44,12 @@ extension NSMutableAttributedString {
44
44
let newRange = NSRange ( location: range. location + offset, length: range. length)
45
45
46
46
guard let unwrappedPath = path, unwrappedPath. count > 0 else { return }
47
- let unrappedTitle = title ?? " "
48
47
49
- if let pathEncoded = unwrappedPath . addingPercentEncoding ( withAllowedCharacters : . urlQueryAllowed ) {
48
+ let unrappedTitle = title ?? " "
50
49
51
- content? . removeAttribute ( . attachment, range: newRange)
52
- content? . replaceCharacters ( in: newRange, with: "  ) " )
53
- offset += 4 + pathEncoded. count + unrappedTitle. count
54
- }
50
+ content? . removeAttribute ( . attachment, range: newRange)
51
+ content? . replaceCharacters ( in: newRange, with: "  ) " )
52
+ offset += 4 + unwrappedPath. count + unrappedTitle. count
55
53
}
56
54
}
57
55
You can’t perform that action at this time.
0 commit comments