Post not yet marked as solved
Post marked as unsolved with 1 replies, 245 views
Hi,
We ended up releasing a bug in our apps because of a view modifier that looks like this:
func body(content: Content) -> some View {
if #available(iOS 16.0, tvOS 16, *) {
content
.scrollDismissesKeyboard(.immediately)
}
}
Obviously, it is missing an else statement just returning content.
But how can this even compile? On iOS < 16 and tvOS < 16 it is returning VOID / NOTHING! while it must return Some View!