diff --git a/Sources/NukeExtensions/ImageViewExtensions.swift b/Sources/NukeExtensions/ImageViewExtensions.swift index e76797d5..2a8d24a0 100644 --- a/Sources/NukeExtensions/ImageViewExtensions.swift +++ b/Sources/NukeExtensions/ImageViewExtensions.swift @@ -413,9 +413,9 @@ extension ImageViewController { transitionView.frame = imageView.frame transitionView.tintColor = imageView.tintColor transitionView.tintAdjustmentMode = imageView.tintAdjustmentMode - #if swift(>=5.9) // preferredImageDynamicRange was back-ported to all iOS/tvOS versions, but only available when using the iOS/tvOS 17+ SDKs - transitionView.preferredImageDynamicRange = imageView.preferredImageDynamicRange - #endif + if #available(iOS 17.0, tvOS 17.0, *) { + transitionView.preferredImageDynamicRange = imageView.preferredImageDynamicRange + } transitionView.preferredSymbolConfiguration = imageView.preferredSymbolConfiguration transitionView.isHidden = imageView.isHidden transitionView.clipsToBounds = imageView.clipsToBounds