canOpenURL not working in ios 10
<p>The above code is always returning false</p>

<pre><code>if {(UIApplication.shared.canOpenURL(URL(string:"comgooglemaps://")!))}
</code></pre>

<p>I guess this a problem found in iOS10. 
I am trying to open google maps app if there in one installed or try to open apple maps so wanted to use canOpenURL . are there any alternatives  </p>