Skip to content

Commit

Permalink
Fix crash when URL is configured to non-http/https scheme (#1279)
Browse files Browse the repository at this point in the history
Fixes #1252.
  • Loading branch information
zacwest committed Nov 18, 2020
1 parent 67d4bde commit ee69316
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/App/WebView/WebViewController.swift
Expand Up @@ -191,7 +191,7 @@ class WebViewController: UIViewController, WKNavigationDelegate, WKUIDelegate, U
return
}

guard scheme.hasPrefix("http") else {
guard ["http", "https"].contains(scheme) else {
Current.Log.warning("Was going to provide invalid URL to NSUserActivity! \(currentURL)")
return
}
Expand Down

0 comments on commit ee69316

Please sign in to comment.