Skip to content

Commit

Permalink
Fix 'initializer for conditional binding must have Optional type, not…
Browse files Browse the repository at this point in the history
… 'AnyView'' error under Swift 5.8 development snapshot tools.
  • Loading branch information
JetForMe committed Feb 13, 2023
1 parent 2db4691 commit 75041a4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/SwiftUI/KFImageRenderer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ struct KFImageRenderer<HoldingView> : View where HoldingView: KFImageHoldingView
renderedImage().opacity(binder.loaded ? 1.0 : 0.0)
if binder.loadedImage == nil {
ZStack {
if let placeholder = context.placeholder, let view = placeholder(binder.progress) {
view
if let placeholder = context.placeholder {
placeholder(binder.progress)
} else {
Color.clear
}
Expand Down

0 comments on commit 75041a4

Please sign in to comment.