Invalid conversion from throwing function of type (_,_,_) throws -> Void to non-throwing function type (NSData?, NSURLResponse?, NSError?) -> Void

You need to implement Do Try Catch error handling as follow: import UIKit import PlaygroundSupport PlaygroundPage.current.needsIndefiniteExecution = true extension URL { func asyncDownload(completion: @escaping (_ data: Data?, _ response: URLResponse?, _ error: Error?) -> ()) { URLSession.shared .dataTask(with: self, completionHandler: completion) .resume() } } let jsonURL = URL(string: “https://api.whitehouse.gov/v1/petitions.json?limit=100”)! let start = Date() jsonURL.asyncDownload { … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)