Fix links not getting cleared on cell reuse

This commit is contained in:
Shadowfacts 2019-02-07 21:26:16 -05:00
parent 2e7d2c2a30
commit 2d65a17240
1 changed files with 1 additions and 1 deletions

View File

@ -31,10 +31,10 @@ class ContentLabel: LinkLabel {
mutAttrString.addAttribute(.font, value: font, range: NSRange(location: 0, length: mutAttrString.length))
self.links = []
let linkAttributes: [NSAttributedString.Key: Any] = [
.foregroundColor: UIColor.blue,
]
for (range, url) in links {
mutAttrString.addAttributes(linkAttributes, range: range)
self.links.append(Link(range: range, url: url))