Avatar
Because dataTask(with:completionHandler:) returns a URLSessionDataTask, it is impossible to be converted into async/await directly. I think we need an extension method like below. extension URLSessionDataTask { func completion() async throws -> (Data, URLResponse) { ... ...
6:25 AM
completion の件書いておいた
6:28 AM
NSErrorがURLResponseを保持しない事に驚いたって言ってるのかな・・・
概ねそんな感じかと。