I'm the new on swift. I have a question how to save image from url into permanent cache. Since URL live for only 30min and is expired after 30min, I'm using sdwebimage and saving image in disk and memory cache. My code is like the below. and it's working well. Problem is that sometimes image is not loaded because of unknown issue. I guessed that image is not saved permanently in cache..This is just my guess. So, I'd like to save image permanent cache. How can I do this? Or Is there anyone know why this symptom is observed?
My code :
cell.imageView.sd_setImage(with: URL(string: url), placeholderImage: nil)