Przeglądaj źródła

Optional resource

onevcat 6 lat temu
rodzic
commit
0510862b29

+ 1 - 1
Sources/Extensions/WKInterfaceImage+Kingfisher.swift

@@ -154,7 +154,7 @@ extension KingfisherWrapper where Base: WKInterfaceImage {
         completionHandler: ((Result<RetrieveImageResult, KingfisherError>) -> Void)? = nil) -> DownloadTask?
     {
         return setImage(
-            with: resource.convertToSource(),
+            with: resource?.convertToSource(),
             placeholder: placeholder,
             options: options,
             progressBlock: progressBlock,