I have this code:
func openPDFFromInternet(www: String){
let serwerUrl = ApiConstans.fullPath + "" + www
let url = NSURL(string: www)
print("the url = \(url)")
UIApplication.shared.open(URL(string : www)!)
}
www has value: "
/Users/imac/Library/Developer/CoreSimulator/Devices/A2B19B93-A0AD-46DF-923F-E18DD76EAC96/data/Containers/Data/Application/A37F7B0E-3B67-42E8-B616-5C3066F5653F/Documents/eng/PDF/MyFile RostiBites2015-ENG new_OK-prev.pdf"
Print return me nil.
When I run this code I have error:
Thread 1: Fatal error: Unexpectedly found nil while unwrapping an Optional value
Does anyone know repair it? I have file in this path. I can't rename my filename