Xcode 15. Method 'setImage' error No exact matches in call to instance method 'setImage' #2151
Unanswered
JimmyBlackyB
asked this question in
Q&A
Replies: 1 comment
-
Problem fixed. Changing the ImageResource type to KF.ImageResource. Thank you for your attention. Xcode 15 is "wonderful". P.S. That was sarcasm. =) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi. After upgrading to Xcode 15, when compiling the project I get an error No exact matches in call to instance method 'setImage' on the setImage method. I am using the latest version 7.9.1. Help me out here, please.
extension UIImageView { private func kfSetImage( resourse: ImageResource, useShimmer: Bool, cacheName: CacheName?, useDefaultImage: Bool, completionHandler: VoidCallback?, withOptions: [KingfisherOptionsInfoItem] = [], resize: CGSize? ) { let shimmerView = useShimmer ? ShimmerView() : nil var options = TImageCache.getKfOptions(cacheName: cacheName) options.append(contentsOf: withOptions) self.kf.setImage(with: resourse, placeholder: shimmerView, options: options, completionHandler: { result in switch result { case .success(let imageResult): if let resize = resize { self.image = imageResult.image.resized(to: resize) } else { self.image = imageResult.image } case .failure(_): if let resize = resize { self.image = useDefaultImage ? .defaultImage.resized(to: resize) : nil } else { self.image = useDefaultImage ? .defaultImage : nil } } shimmerView?.removeFromSuperview() completionHandler?() }) } }
Beta Was this translation helpful? Give feedback.
All reactions