     }
 
     // Add prefix image if needed
+    fileprivate func addImagePrefixIfNeeded(_ image: String, url: URL) -> String {
+        addImagePrefixIfNeeded( image, canonicalUrl: self.extractCanonicalURL( url ), finalUrl: self.extractInURLRedirectionIfNeeded( url ).absoluteString )
+    }
+
     fileprivate func addImagePrefixIfNeeded(_ image: String, result: Response) -> String {
-
+        addImagePrefixIfNeeded( image, canonicalUrl: result.canonicalUrl, finalUrl: result.finalUrl?.absoluteString )
+    }
+
+    fileprivate func addImagePrefixIfNeeded(_ image: String, canonicalUrl: String?, finalUrl: String?) -> String {
         var image = image
 
-        if let canonicalUrl = result.canonicalUrl, let finalUrl = result.finalUrl?.absoluteString {
+        // TODO: account for HTML <base>
+        if let canonicalUrl = canonicalUrl, let finalUrl = finalUrl {
             if finalUrl.hasPrefix("https:") {
                 if image.hasPrefix("//") {
                     image = "https:" + image

            } else {
                if let finalResult = response?.url {
                    if (finalResult.absoluteString == url.absoluteString) {
                        self.workQueue.async {
                            if !cancellable.isCancelled {
                                completion(url)
                            }
                        }
                        task = nil
                    } else {
                        task?.cancel()
                        task = nil

        request.httpMethod = "HEAD"

        task = session.dataTask(with: request, completionHandler: { data, response, error in
            guard !cancellable.isCancelled
            else { return }

            if error != nil {
                self.workQueue.async {
                    if !cancellable.isCancelled {
