             localizedString,
             "<a href=\"#LOGIN_HREF\">", // "#LOGIN_HREF" ensures 'byAttributingHTML' doesn't strip the anchor. The entire text view uses a tap recognizer so the string itself is unimportant.
             "</a>"
-        )
+        ).stringTrimmingWhitespaceInsideAnchor()
         
         let attributedString = substitutedString.byAttributingHTML(with: .caption2, matching: traitCollection)
         

            "</a>" ,
            "<a href=\"\(Licenses.GFDLURL?.absoluteString ?? "")\">",
            "</a>"
        )
        
        let attributedString = substitutedString.byAttributingHTML(with: .caption2, matching: traitCollection)
        

        adjustHeightOfSpacerAboveBottomDividerSoContentViewIsAtLeastHeightOfScrollView()
    }
}

private extension String {
    func stringTrimmingWhitespaceInsideAnchor() -> String {
        return replacingOccurrences(of: ">\\s*(.*?)\\s*</a>", with: ">$1</a>", options: [.regularExpression])
    }
}
