Fix the example crash issue of ObjcClass, should check meta type but not instance type

This commit is contained in:
DreamPiggy 2020-01-26 20:53:20 +08:00
parent c92240b4af
commit fe54241aca
1 changed files with 1 additions and 1 deletions

View File

@ -26,7 +26,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
// Dynamic check to support both WebImage/AnimatedImage
SDWebImageManager.shared.optionsProcessor = SDWebImageOptionsProcessor { url, options, context in
var context = context
if let _ = context?[.animatedImageClass] as? SDAnimatedImageProtocol {
if let _ = context?[.animatedImageClass] as? SDAnimatedImage.Type {
// AnimatedImage supports vector rendering
} else {
// WebImage supports bitmap rendering only