             let URL: NSURL? = {
                 if let string = value as? String {
                     return NSURL(string: string)
-                } else if let URL = value as? NSURL {
-                    return URL
-                }
-                return nil
+                } else {
+                    return value as? NSURL
+                }
             }()
             
             if let URL = URL {

    
    private func linkRangeAtPoint(point: CGPoint) -> LinkRange? {
        if let linkRanges = linkRanges {
            textContainer.size = CGSize(width: CGRectGetWidth(bounds), height: CGFloat.max)
            layoutManager.ensureLayoutForTextContainer(textContainer)
            

    }
    
    // MARK: Attributes
    
    private struct DefaultLinkAttributes {
        static var Color = UIColor.blueColor()
        static var UnderlineStyle = NSUnderlineStyle.StyleSingle
    }

    private func processLinks() {
        var ranges = [LinkRange]()
