After increasing the minimum OS deployment to iOS 18, we can remove the `if #available(iOS 17.0, *)` complier directives and just keep the else case.