Skip to content
This repository was archived by the owner on Feb 17, 2025. It is now read-only.

Commit d5b529c

Browse files
authored
No Bug - Lint Fixes (#4637)
* Fix vertical whitespace. * Fix calls to super. * Fix redundant type annotation. * Fix colons. * Remove semicolons, fix some spacing, remove nil for optionals. * A bit more cleanup. * Cleanup some errors in the linting process. move files out of the root dir.
1 parent 34e1678 commit d5b529c

File tree

69 files changed

+115
-131
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+115
-131
lines changed

Diff for: .swiftlint.yml

+12
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,18 @@ opt_in_rules: # some rules are only opt-in
4646
- explicit_init
4747
- shorthand_operator
4848
- file_header
49+
- deployment_target
50+
- discouraged_optional_collection
51+
- duplicate_imports
52+
- empty_string
53+
- implicit_return
54+
- overridden_super_call
55+
- prohibited_interface_builder
56+
- prohibited_super_call
57+
- protocol_property_accessors_order
58+
- redundant_objc_attribute
59+
- redundant_type_annotation
60+
- unused_import
4961
# Find all the available rules by running:
5062
# swiftlint rules
5163
included: # paths to include during linting. `--path` is ignored if present.

Diff for: Account/FirefoxAccount.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ open class FirefoxAccount {
178178
}
179179

180180
fileprivate class func fromDictionaryV1(_ dictionary: [String: Any]) -> FirefoxAccount? {
181-
var configurationLabel: FirefoxAccountConfigurationLabel? = nil
181+
var configurationLabel: FirefoxAccountConfigurationLabel?
182182
if let rawValue = dictionary["configurationLabel"] as? String {
183183
configurationLabel = FirefoxAccountConfigurationLabel(rawValue: rawValue)
184184
}

Diff for: Account/FxAClient10.swift

+16-16
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public struct FxAOAuthResponse {
7979
self.expires = expires
8080
}
8181

82-
init?(dictionary: [String : Any]) {
82+
init?(dictionary: [String: Any]) {
8383
guard let accessToken = dictionary["accessToken"] as? String,
8484
let expiresTimeInterval = dictionary["expires"] as? TimeInterval else {
8585
return nil
@@ -89,7 +89,7 @@ public struct FxAOAuthResponse {
8989
self.expires = Date(timeIntervalSince1970: expiresTimeInterval)
9090
}
9191

92-
public func dictionary() -> [String : Any] {
92+
public func dictionary() -> [String: Any] {
9393
return [
9494
"accessToken": accessToken,
9595
"expires": expires.timeIntervalSince1970
@@ -205,7 +205,7 @@ open class FxAClient10 {
205205
}
206206

207207
open class func computeUnwrapKey(_ stretchedPW: Data) -> Data {
208-
let salt: Data = Data()
208+
let salt = Data()
209209
let contextInfo: Data = KW("unwrapBkey")
210210
let bytes = (stretchedPW as NSData).deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(KeyLength))
211211
return bytes!
@@ -254,7 +254,7 @@ open class FxAClient10 {
254254
let ciphertext = data.subdata(in: 0..<(2 * KeyLength))
255255
let MAC = data.subdata(in: (2 * KeyLength)..<(3 * KeyLength))
256256

257-
let salt: Data = Data()
257+
let salt = Data()
258258
let contextInfo: Data = KW("account/keys")
259259
let bytes = (keyRequestKey as NSData).deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(3 * KeyLength))
260260
let respHMACKey = bytes?.subdata(in: 0..<KeyLength)
@@ -438,7 +438,7 @@ open class FxAClient10 {
438438

439439
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
440440

441-
let salt: Data = Data()
441+
let salt = Data()
442442
let contextInfo: Data = FxAClient10.KW("sessionToken")
443443
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
444444
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -484,7 +484,7 @@ open class FxAClient10 {
484484
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
485485
mutableURLRequest.httpBody = httpBody.stringify()?.utf8EncodedData
486486

487-
let salt: Data = Data()
487+
let salt = Data()
488488
let contextInfo: Data = FxAClient10.KW("sessionToken")
489489
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
490490
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -495,12 +495,12 @@ open class FxAClient10 {
495495
open func destroyDevice(ownDeviceId: GUID, withSessionToken sessionToken: NSData) -> Deferred<Maybe<FxADeviceDestroyResponse>> {
496496
let URL = self.authURL.appendingPathComponent("/account/device/destroy")
497497
var mutableURLRequest = URLRequest(url: URL)
498-
let httpBody: JSON = JSON(["id": ownDeviceId])
498+
let httpBody = JSON(["id": ownDeviceId])
499499
mutableURLRequest.httpMethod = HTTPMethod.post.rawValue
500500
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
501501
mutableURLRequest.httpBody = httpBody.stringify()?.utf8EncodedData
502502

503-
let salt: Data = Data()
503+
let salt = Data()
504504
let contextInfo: Data = FxAClient10.KW("sessionToken")
505505
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
506506
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -522,7 +522,7 @@ open class FxAClient10 {
522522
mutableURLRequest.httpMethod = HTTPMethod.get.rawValue
523523
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
524524

525-
let salt: Data = Data()
525+
let salt = Data()
526526
let contextInfo: Data = FxAClient10.KW("sessionToken")
527527
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
528528
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -533,12 +533,12 @@ open class FxAClient10 {
533533
open func invokeCommand(name: String, targetDeviceID: GUID, payload: String, withSessionToken sessionToken: NSData) -> Deferred<Maybe<FxASendMessageResponse>> {
534534
let URL = self.authURL.appendingPathComponent("/account/devices/invoke_command")
535535
var mutableURLRequest = URLRequest(url: URL)
536-
let httpBody: JSON = JSON(["command": name, "target": targetDeviceID, "payload": ["encrypted": payload]])
536+
let httpBody = JSON(["command": name, "target": targetDeviceID, "payload": ["encrypted": payload]])
537537
mutableURLRequest.httpMethod = HTTPMethod.post.rawValue
538538
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
539539
mutableURLRequest.httpBody = httpBody.stringify()?.utf8EncodedData
540540

541-
let salt: Data = Data()
541+
let salt = Data()
542542
let contextInfo: Data = FxAClient10.KW("sessionToken")
543543
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
544544
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -554,7 +554,7 @@ open class FxAClient10 {
554554
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
555555
mutableURLRequest.httpBody = device.toJSON().rawString(options: [])?.utf8EncodedData
556556

557-
let salt: Data = Data()
557+
let salt = Data()
558558
let contextInfo: Data = FxAClient10.KW("sessionToken")
559559
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
560560
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -617,7 +617,7 @@ open class FxAClient10 {
617617
"ttl": "21600" // 6 hours
618618
]
619619

620-
let salt: Data = Data()
620+
let salt = Data()
621621
let contextInfo: Data = FxAClient10.KW("sessionToken")
622622
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
623623

@@ -703,7 +703,7 @@ extension FxAClient10: FxALoginClient {
703703
var mutableURLRequest = URLRequest(url: URL)
704704
mutableURLRequest.httpMethod = HTTPMethod.get.rawValue
705705

706-
let salt: Data = Data()
706+
let salt = Data()
707707
let contextInfo: Data = FxAClient10.KW("keyFetchToken")
708708
let key = (keyFetchToken as NSData).deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(3 * KeyLength))!
709709
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -727,7 +727,7 @@ extension FxAClient10: FxALoginClient {
727727
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
728728
mutableURLRequest.httpBody = JSON(parameters as NSDictionary).stringify()?.utf8EncodedData
729729

730-
let salt: Data = Data()
730+
let salt = Data()
731731
let contextInfo: Data = FxAClient10.KW("sessionToken")
732732
let key = sessionToken.deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
733733
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)
@@ -751,7 +751,7 @@ extension FxAClient10: FxALoginClient {
751751
mutableURLRequest.setValue("application/json", forHTTPHeaderField: "Content-Type")
752752
mutableURLRequest.httpBody = JSON(parameters as NSDictionary).stringify()?.utf8EncodedData
753753

754-
let salt: Data = Data()
754+
let salt = Data()
755755
let contextInfo: Data = FxAClient10.KW("sessionToken")
756756
let key = (sessionToken as NSData).deriveHKDFSHA256Key(withSalt: salt, contextInfo: contextInfo, length: UInt(2 * KeyLength))!
757757
mutableURLRequest.addAuthorizationHeader(forHKDFSHA256Key: key)

Diff for: Account/HawkHelper.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ open class HawkHelper {
1919

2020
// Produce a HAWK value suitable for an "Authorization: value" header, timestamped now.
2121
open func getAuthorizationValueFor(_ request: URLRequest) -> String {
22-
let timestampInSeconds: Int64 = Int64(Date().timeIntervalSince1970)
22+
let timestampInSeconds = Int64(Date().timeIntervalSince1970)
2323
return getAuthorizationValueFor(request, at: timestampInSeconds)
2424
}
2525

Diff for: Account/KeyBundle.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ open class KeyBundle: Hashable {
4646

4747
fileprivate func _hmac(_ ciphertext: Data) -> (data: UnsafeMutablePointer<CUnsignedChar>, len: Int) {
4848
let hmacAlgorithm = CCHmacAlgorithm(kCCHmacAlgSHA256)
49-
let digestLen: Int = Int(CC_SHA256_DIGEST_LENGTH)
49+
let digestLen = Int(CC_SHA256_DIGEST_LENGTH)
5050
let result = UnsafeMutablePointer<CUnsignedChar>.allocate(capacity: digestLen)
5151
CCHmac(hmacAlgorithm, hmacKey.getBytes(), hmacKey.count, ciphertext.getBytes(), ciphertext.count, result)
5252
return (result, digestLen)

Diff for: Client.xcodeproj/project.pbxproj

+6-10
Original file line numberDiff line numberDiff line change
@@ -486,7 +486,6 @@
486486
D821E90E2141B71C00452C55 /* SiriSettingsViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = D821E9052141B71C00452C55 /* SiriSettingsViewController.swift */; };
487487
D82ED2641FEB3C420059570B /* DefaultSearchPrefsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D82ED2631FEB3C420059570B /* DefaultSearchPrefsTests.swift */; };
488488
D83822001FC7961D00303C12 /* DispatchQueueExtensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = D83821FF1FC7961D00303C12 /* DispatchQueueExtensions.swift */; };
489-
D86064AF2204CF7D000CED85 /* ActivityStreamTopics.swift in Sources */ = {isa = PBXBuildFile; fileRef = E69DB0BA1E97E301008A67E6 /* ActivityStreamTopics.swift */; };
490489
D863C8F21F68BFC20058D95F /* GradientProgressBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = D863C8E31F68BFC20058D95F /* GradientProgressBar.swift */; };
491490
D87F84AC20B891160091F2DA /* TabDisplayManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = D87F84AB20B891160091F2DA /* TabDisplayManager.swift */; };
492491
D88FDA9F1F4E2B9200FD9709 /* PhotonActionSheetProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = D88FDA9E1F4E2B9200FD9709 /* PhotonActionSheetProtocol.swift */; };
@@ -1289,7 +1288,6 @@
12891288
28CE83BE1A1D1D3200576538 /* Record.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Record.swift; sourceTree = "<group>"; };
12901289
28CE83BF1A1D1D3200576538 /* SyncMeta.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SyncMeta.swift; sourceTree = "<group>"; };
12911290
28CE83CA1A1D1D5100576538 /* FxA.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = FxA.xcodeproj; path = FxA/FxA.xcodeproj; sourceTree = "<group>"; };
1292-
28CE83E81A1D206D00576538 /* Client-Bridging-Header.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "Client-Bridging-Header.h"; path = "../../Client-Bridging-Header.h"; sourceTree = "<group>"; };
12931291
28D158AC1AFD90E500F9C065 /* TestSQLiteBookmarks.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestSQLiteBookmarks.swift; sourceTree = "<group>"; };
12941292
28D52E081BCDF44100187A1D /* ResetTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ResetTests.swift; sourceTree = "<group>"; };
12951293
28D980221C47149000277055 /* TestBookmarkTreeMerging.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = TestBookmarkTreeMerging.swift; path = SyncTests/TestBookmarkTreeMerging.swift; sourceTree = "<group>"; };
@@ -1664,6 +1662,7 @@
16641662
D3FA77831A43B2CE0010CD32 /* OpenSearch.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = OpenSearch.swift; sourceTree = "<group>"; };
16651663
D3FEC38C1AC4B42F00494F45 /* AutocompleteTextField.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AutocompleteTextField.swift; sourceTree = "<group>"; };
16661664
D81127D71F84023B0050841D /* PhotonActionSheetTest.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PhotonActionSheetTest.swift; sourceTree = "<group>"; };
1665+
D81E377D2242FF61006AC72D /* Client-Bridging-Header.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "Client-Bridging-Header.h"; path = "Client/Client-Bridging-Header.h"; sourceTree = SOURCE_ROOT; };
16671666
D81E45121F82C56C004EFFBA /* NewTabContentSettingsViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NewTabContentSettingsViewController.swift; sourceTree = "<group>"; };
16681667
D821E9052141B71C00452C55 /* SiriSettingsViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SiriSettingsViewController.swift; sourceTree = "<group>"; };
16691668
D82ED2631FEB3C420059570B /* DefaultSearchPrefsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DefaultSearchPrefsTests.swift; sourceTree = "<group>"; };
@@ -1843,7 +1842,6 @@
18431842
E69DB07D1E97DEA9008A67E6 /* SyncTelemetryTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = SyncTelemetryTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
18441843
E69DB0861E97DEAA008A67E6 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
18451844
E69DB0B51E97E2AC008A67E6 /* SyncTelemetry.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SyncTelemetry.swift; sourceTree = "<group>"; };
1846-
E69DB0BA1E97E301008A67E6 /* ActivityStreamTopics.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ActivityStreamTopics.swift; sourceTree = "<group>"; };
18471845
E69DB0C01E97E320008A67E6 /* BookmarkTelemetryPing.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = BookmarkTelemetryPing.swift; sourceTree = "<group>"; };
18481846
E69E06B91C76173D00D0F926 /* RequirePasscodeIntervalViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = RequirePasscodeIntervalViewController.swift; sourceTree = "<group>"; };
18491847
E69E06C81C76198000D0F926 /* AuthenticationManagerConstants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AuthenticationManagerConstants.swift; sourceTree = "<group>"; };
@@ -3307,7 +3305,6 @@
33073305
E69DB0B91E97E301008A67E6 /* Telemetry */ = {
33083306
isa = PBXGroup;
33093307
children = (
3310-
E69DB0BA1E97E301008A67E6 /* ActivityStreamTopics.swift */,
33113308
EBF47E6F1F7979DF00899189 /* UnifiedTelemetry.swift */,
33123309
);
33133310
path = Telemetry;
@@ -3529,7 +3526,7 @@
35293526
children = (
35303527
19DE1F661EC13B6400428B8C /* LeanplumIntegration.swift */,
35313528
E652F6F91BF66A79007FFDD6 /* Delegates */,
3532-
28CE83E81A1D206D00576538 /* Client-Bridging-Header.h */,
3529+
D81E377D2242FF61006AC72D /* Client-Bridging-Header.h */,
35333530
E40FAB0B1A7ABB77009CB80D /* WebServer.swift */,
35343531
E4D6BEB81A0930EC00F538BD /* LaunchScreen.xib */,
35353532
D3BE7B251B054D4400641031 /* main.swift */,
@@ -5091,7 +5088,6 @@
50915088
isa = PBXSourcesBuildPhase;
50925089
buildActionMask = 2147483647;
50935090
files = (
5094-
D86064AF2204CF7D000CED85 /* ActivityStreamTopics.swift in Sources */,
50955091
E69DB0B71E97E2AC008A67E6 /* SyncTelemetry.swift in Sources */,
50965092
EBA31D7B1F79990C0055463D /* SyncTelemetryEvents.swift in Sources */,
50975093
);
@@ -6541,7 +6537,7 @@
65416537
PRODUCT_MODULE_NAME = Client;
65426538
PRODUCT_NAME = Client;
65436539
PROVISIONING_PROFILE_SPECIFIER = "Firefox Development";
6544-
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client-Bridging-Header.h";
6540+
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client/Client-Bridging-Header.h";
65456541
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
65466542
SWIFT_VERSION = 4.0;
65476543
};
@@ -7460,7 +7456,7 @@
74607456
PRODUCT_NAME = Client;
74617457
PROVISIONING_PROFILE_SPECIFIER = "FennecEnterprise Development";
74627458
SWIFT_ACTIVE_COMPILATION_CONDITIONS = BUDDYBUILD;
7463-
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client-Bridging-Header.h";
7459+
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client/Client-Bridging-Header.h";
74647460
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
74657461
SWIFT_VERSION = 4.0;
74667462
};
@@ -8018,7 +8014,7 @@
80188014
PRODUCT_MODULE_NAME = Client;
80198015
PRODUCT_NAME = Client;
80208016
PROVISIONING_PROFILE_SPECIFIER = "Firefox Beta Development";
8021-
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client-Bridging-Header.h";
8017+
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client/Client-Bridging-Header.h";
80228018
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
80238019
SWIFT_VERSION = 4.0;
80248020
};
@@ -8409,7 +8405,7 @@
84098405
PRODUCT_NAME = Client;
84108406
PROVISIONING_PROFILE_SPECIFIER = "Fennec Development";
84118407
SWIFT_ACTIVE_COMPILATION_CONDITIONS = BUDDYBUILD;
8412-
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client-Bridging-Header.h";
8408+
SWIFT_OBJC_BRIDGING_HEADER = "$(PROJECT_DIR)/Client/Client-Bridging-Header.h";
84138409
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
84148410
SWIFT_VERSION = 4.0;
84158411
};

Diff for: Client/Application/AppDelegate.swift

+2-4
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UIViewControllerRestorati
7272
// If the 'Save logs to Files app on next launch' toggle
7373
// is turned on in the Settings app, copy over old logs.
7474
if DebugSettingsBundleOptions.saveLogsToDocuments {
75-
Logger.copyPreviousLogsToDocuments();
75+
Logger.copyPreviousLogsToDocuments()
7676
}
7777

7878
return startApplication(application, withLaunchOptions: launchOptions)
@@ -116,7 +116,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UIViewControllerRestorati
116116
class_addMethod(clazz, MenuHelper.SelectorFindInPage, method_getImplementation(swizzledMethod), method_getTypeEncoding(swizzledMethod))
117117
}
118118

119-
120119
self.tabManager = TabManager(profile: profile, imageStore: imageStore)
121120

122121
// Add restoration class, the factory that will return the ViewController we
@@ -235,7 +234,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UIViewControllerRestorati
235234
return shouldPerformAdditionalDelegateHandling
236235
}
237236

238-
func application(_ application: UIApplication, open url: URL, options: [UIApplicationOpenURLOptionsKey : Any] = [:]) -> Bool {
237+
func application(_ application: UIApplication, open url: URL, options: [UIApplicationOpenURLOptionsKey: Any] = [:]) -> Bool {
239238
guard let routerpath = NavigationPath(url: url) else {
240239
return false
241240
}
@@ -249,7 +248,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UIViewControllerRestorati
249248
UnifiedTelemetry.recordEvent(category: .appExtensionAction, method: .applicationOpenUrl, object: object)
250249
}
251250

252-
253251
DispatchQueue.main.async {
254252
NavigationPath.handle(nav: routerpath, with: self.browserViewController)
255253
}

0 commit comments

Comments
 (0)