refactor: Remove unused stripHTMLSimple method from StringExtensions

- Remove stripHTMLSimple regex-based HTML stripping method
- Keep stripHTML with NSAttributedString-based implementation (used in codebase)
- Method was not used anywhere in the project
This commit is contained in:
Ilyas Hallak 2025-12-01 22:06:52 +01:00
parent fcf6c3e441
commit 358037427c

View File

@ -13,17 +13,5 @@ extension String {
)
return attributedString?.string ?? self
}
var stripHTMLSimple: String {
// Einfache Regex-basierte HTML-Entfernung
return self.replacingOccurrences(of: "<[^>]+>", with: "", options: .regularExpression, range: nil)
.replacingOccurrences(of: "&nbsp;", with: " ")
.replacingOccurrences(of: "&amp;", with: "&")
.replacingOccurrences(of: "&lt;", with: "<")
.replacingOccurrences(of: "&gt;", with: ">")
.replacingOccurrences(of: "&quot;", with: "\"")
.replacingOccurrences(of: "&#39;", with: "'")
.trimmingCharacters(in: .whitespacesAndNewlines)
}
}
}
}