I want to download image and when I run app my app crashed because the image string of json file is like this :
images/product/2021-05-02T09-47-17.699Z-download (2).jpg
there is a distance between download and (2) in my json file and its the problem that make an app crash , in browser its worked but in Xcode not , what's your idea to solve it?
and here is a part of my code when I want to download image :
let imageUrl = URL(string: "http://5.63.13.16:8080/\(item.image.first!)")!
if let data = try? Data(contentsOf: imageUrl) {
cellol.offerImageView.image = UIImage(data: data)
}