                 resources += cssPaths
             }
 
-            completionHandler(data: data, resources: resources, error: nil)
+            completionHandler(data: data, metaData: metaData, resources: resources, error: nil)
         }
         task.resume()
     }

     */
    public static func logHTMLResources(fromUrl url: NSURL) {

        self.resourcePathsFromUrl(url, fetchOptions: [.FetchImage, .FetchJs, .FetchCss]) { (data, resources, error) in
            guard let resources = resources else {
                printLog("resource fetch error : \(error)")
                return


            guard let htmlData = data else {
                printLog("fetch html error : \(error)")
                completionHandler(data: data, metaData: nil, resources: nil, error: ArchiveErrorType.FetchHTMLError)
                return
            }

            guard let html = (NSString(data: htmlData, encoding: NSUTF8StringEncoding) as? String) else {
                printLog("html invalid")
                completionHandler(data: data, metaData: nil, resources: nil, error: ArchiveErrorType.HTMLInvalid)
                return
            }

            guard let doc = try? HTMLDocument(string: html, encoding: NSUTF8StringEncoding) else {
                printLog("init html doc error, html : \(html)")
                completionHandler(data: data, metaData: nil, resources: nil, error: ArchiveErrorType.FailToInitHTMLDocument)
                return
            }

            printLog("html --> \(html)")
            
            var metaData = [String: String?]()
            if let htmlTitle = doc.title {
                metaData[ArchivedWebpageMetaKeyTitle] = htmlTitle
            }

            var resources: [String] = []

