From 8a4136b7cefd5563d855fd309efe840c1a046764 Mon Sep 17 00:00:00 2001 From: Danny Moesch Date: Mon, 10 Aug 2020 23:14:12 +0200 Subject: [PATCH] Enable SwiftLint rule 'computed_accessors_order' and fix all violations --- .swiftlint.yml | 1 + passKit/Models/PasswordStore.swift | 12 ++++++------ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.swiftlint.yml b/.swiftlint.yml index 01fe2b5..3b4115a 100644 --- a/.swiftlint.yml +++ b/.swiftlint.yml @@ -20,6 +20,7 @@ whitelist_rules: - colon - comma - compiler_protocol_init + - computed_accessors_order - conditional_returns_on_newline - contains_over_filter_count - contains_over_filter_is_empty diff --git a/passKit/Models/PasswordStore.swift b/passKit/Models/PasswordStore.swift index 59a8d63..964eba5 100644 --- a/passKit/Models/PasswordStore.swift +++ b/passKit/Models/PasswordStore.swift @@ -36,21 +36,21 @@ public class PasswordStore { } public var gitPassword: String? { - set { - AppKeychain.shared.add(string: newValue, for: Globals.gitPassword) - } get { AppKeychain.shared.get(for: Globals.gitPassword) } + set { + AppKeychain.shared.add(string: newValue, for: Globals.gitPassword) + } } public var gitSSHPrivateKeyPassphrase: String? { - set { - AppKeychain.shared.add(string: newValue, for: Globals.gitSSHPrivateKeyPassphrase) - } get { AppKeychain.shared.get(for: Globals.gitSSHPrivateKeyPassphrase) } + set { + AppKeychain.shared.add(string: newValue, for: Globals.gitSSHPrivateKeyPassphrase) + } } private let fm = FileManager.default