Remove unnecessary dispatch

This commit is contained in:
Maurice Parker 2019-11-07 15:00:43 -06:00
parent ac2506fd64
commit 94d60fbf34
1 changed files with 20 additions and 20 deletions

View File

@ -15,7 +15,7 @@ class ArticleIconSchemeHandler: NSObject, WKURLSchemeHandler {
var currentArticle: Article?
func webView(_ webView: WKWebView, start urlSchemeTask: WKURLSchemeTask) {
DispatchQueue.main.async {
guard let responseURL = urlSchemeTask.request.url, let iconImage = self.currentArticle?.iconImage() else {
urlSchemeTask.didFailWithError(URLError(.fileDoesNotExist))
return
@ -36,7 +36,7 @@ class ArticleIconSchemeHandler: NSObject, WKURLSchemeHandler {
urlSchemeTask.didReceive(data)
urlSchemeTask.didFinish()
}
}
}
func webView(_ webView: WKWebView, stop urlSchemeTask: WKURLSchemeTask) {