Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fabuloui os fix swift lint warning closure parameter position 434 new #437

1 change: 0 additions & 1 deletion .swiftlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ disabled_rules:
- blanket_disable_command
- for_where
- empty_enum_arguments
- closure_parameter_position

identifier_name:
min_length: 1
Expand Down
8 changes: 4 additions & 4 deletions Scribe/SettingsTab/SettingsViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,8 @@ extension SettingsViewController: UITableViewDelegate {
var data = SettingsTableData.languageSettingsData

// Check if the device is an iPad, and if so don't show the option to put a period and comma on the ABC characters.
let periodCommaOptionIndex = SettingsTableData.languageSettingsData[0].section.firstIndex(where: {
s in s.sectionTitle.elementsEqual("Period and comma on ABC")
let periodCommaOptionIndex = SettingsTableData.languageSettingsData[0].section.firstIndex(where: { s in
s.sectionTitle.elementsEqual("Period and comma on ABC")
}) ?? -1

if DeviceType.isPad {
Expand All @@ -140,8 +140,8 @@ extension SettingsViewController: UITableViewDelegate {

// Languages where we can disable accent keys.
let accentKeyLanguages: [String] = ["Swedish", "German", "Spanish"]
let accentKeyOptionIndex = SettingsTableData.languageSettingsData[0].section.firstIndex(where: {
s in s.sectionTitle.elementsEqual("Disable accent characters")
let accentKeyOptionIndex = SettingsTableData.languageSettingsData[0].section.firstIndex(where: { s in
s.sectionTitle.elementsEqual("Disable accent characters")
}) ?? -1

if accentKeyLanguages.firstIndex(of: section.sectionTitle) == nil && accentKeyOptionIndex != -1 {
Expand Down