After updating to iOS 14 I cannot open urls in the browser if it has been changed from default Safari to Chrome.
I did some investigation and found that UIApplication.shared.canOpenURL(url)
always returns false.
Please help.
For iOS 14+
I suggest to add this to your Info.plist
<key>LSApplicationQueriesSchemes</key>
<array>
<string>https</string>
</array>
By adding this you can continue to use method canOpenURL(_ url: URL) -> Bool
guard let url = URL(string: "https://example.com") else { return }
if UIApplication.shared.canOpenURL(url) {
UIApplication.shared.open(url)
}