Skip to content

Commit

Permalink
cancel image load if there are pending url request on AnimatedImage
Browse files Browse the repository at this point in the history
  • Loading branch information
dreampiggy committed Oct 26, 2019
1 parent 7d4030a commit ad47b58
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions SDWebImageSwiftUI/Classes/AnimatedImage.swift
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@ public struct AnimatedImage : PlatformViewRepresentable {
}

static func dismantleView(_ view: AnimatedImageViewWrapper, coordinator: ()) {
view.wrapped.sd_cancelCurrentImageLoad()
#if os(macOS)
view.wrapped.animates = false
#else
Expand Down

0 comments on commit ad47b58

Please sign in to comment.