Hide the iCloud stats row in Troubleshooting when there's no iCloud account.

This commit is contained in:
Brent Simmons committed 2026-03-25 11:41:00 -07:00
1 parent 4d34947152
commit fbef3d3e9f
1 file changed
+6
@@ -148,6 +148,12 @@ final class SettingsViewController: UITableViewController {
return defaultNumberOfRows
case .articles:
return traitCollection.userInterfaceIdiom == .phone ? 5 : 4
case .troubleshooting:
let defaultNumberOfRows = super.tableView(tableView, numberOfRowsInSection: section)
if !AccountManager.shared.hasiCloudAccount {
return defaultNumberOfRows - 1
}
return defaultNumberOfRows
default:
return super.tableView(tableView, numberOfRowsInSection: section)
}