Просмотр исходного кода

Fix for UIImage placeholder always showing on error

PJ Fechner 3 лет назад
Родитель
Сommit
66a2864872
1 измененных файлов с 1 добавлено и 0 удалено
  1. 1 0
      Sources/Extensions/ImageView+Kingfisher.swift

+ 1 - 0
Sources/Extensions/ImageView+Kingfisher.swift

@@ -362,6 +362,7 @@ extension KingfisherWrapper where Base: KFCrossPlatformImageView {
                         if let image = options.onFailureImage {
                         if let image = options.onFailureImage {
                             self.base.image = image
                             self.base.image = image
                         }
                         }
+                        mutatingSelf.placeholder = nil
                         completionHandler?(result)
                         completionHandler?(result)
                     }
                     }
                 }
                 }