Skip to content

Commit 562884e

Browse files
committed
SwiftLint auto correct
1 parent 456b6be commit 562884e

11 files changed

+141
-141
lines changed

Examples/Demo/AppDelegate.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,11 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
4747

4848
func applicationDidBecomeActive(_ application: UIApplication) {
4949
}
50-
50+
5151
func applicationWillTerminate(_ application: UIApplication) {
5252
}
5353

54-
func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool {
54+
func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey: Any] = [:]) -> Bool {
5555
print("-- called application(_:open:options:) --")
5656
return Studyplus.shared.handle(appDelegateUrl: url)
5757
}

Examples/Demo/ViewController.swift

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -31,77 +31,77 @@ class ViewController: UIViewController, StudyplusLoginDelegate {
3131

3232
@IBOutlet weak var isConnectedLabel: UILabel!
3333
@IBOutlet weak var resultLabel: UILabel!
34-
34+
3535
var duration: TimeInterval = TimeInterval()
36-
36+
3737
override func viewDidLoad() {
3838
super.viewDidLoad()
3939
Studyplus.shared.delegate = self
4040
}
41-
41+
4242
// MARK: - Label
4343

4444
private func updateIsConnected() {
4545
isConnectedLabel.text = Studyplus.shared.isConnected() ? "True" : "False"
4646
}
4747

4848
// MARK: - Button Action
49-
49+
5050
@IBAction func loginButton(_ sender: UIButton) {
5151
Studyplus.shared.login()
5252
}
53-
53+
5454
@IBAction func logoutButton(_ sender: UIButton) {
5555
Studyplus.shared.logout()
5656
updateIsConnected()
5757
resultLabel.text = "Logout"
5858
}
59-
59+
6060
@IBAction func connectedButton(_ sender: UIButton) {
6161
updateIsConnected()
6262
resultLabel.text = ""
6363
}
64-
64+
6565
@IBAction func postStudyRecordButton(_ sender: UIButton) {
66-
66+
6767
self.resultLabel.text = ""
68-
68+
6969
let recordAmount: StudyplusRecordAmount = StudyplusRecordAmount(amount: 10)
7070
let record: StudyplusRecord = StudyplusRecord(duration: duration, recordedAt: Date(), amount: recordAmount, comment: "Today, I studied like anything.")
7171

72-
Studyplus.shared.post(studyRecord: record, success: {
73-
72+
Studyplus.shared.post(studyRecord: record, success: {
73+
7474
self.resultLabel.text = "Success to post your studyRecord to Studyplus App"
75-
75+
7676
}, failure: { error in
77-
77+
7878
self.resultLabel.text = "Error Code: \(error.code()), Message: \(error.message())"
7979
})
8080
}
81-
81+
8282
// MARK: - Picker
83-
83+
8484
@IBAction func studyRecordDurationPicker(_ sender: UIDatePicker) {
8585
duration = sender.countDownDuration
8686
}
87-
87+
8888
// MARK: - StudyplusLoginDelegate
8989

9090
func studyplusDidSuccessToLogin() {
9191
print("-- Called studyplusDidSuccessToLogin --")
9292
resultLabel.text = "Login succeeded"
9393
updateIsConnected()
9494
}
95-
95+
9696
func studyplusDidFailToLogin(error: StudyplusError) {
9797
print("-- Called studyplusDidFailToLogin --")
9898
resultLabel.text = "Error Code: \(error.code()), Message: \(error.message())"
9999
updateIsConnected()
100100
}
101-
101+
102102
func studyplusDidCancelToLogin() {
103103
print("-- Called studyplusDidCancelToLogin --")
104104
resultLabel.text = "Login canceled"
105105
updateIsConnected()
106-
}
106+
}
107107
}

Examples/DemoTests/DemoTests.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,27 +28,27 @@ import XCTest
2828
@testable import Demo
2929

3030
class DemoTests: XCTestCase {
31-
31+
3232
override func setUp() {
3333
super.setUp()
3434
// Put setup code here. This method is called before the invocation of each test method in the class.
3535
}
36-
36+
3737
override func tearDown() {
3838
// Put teardown code here. This method is called after the invocation of each test method in the class.
3939
super.tearDown()
4040
}
41-
41+
4242
func testExample() {
4343
// This is an example of a functional test case.
4444
// Use XCTAssert and related functions to verify your tests produce the correct results.
4545
}
46-
46+
4747
func testPerformanceExample() {
4848
// This is an example of a performance test case.
4949
self.measure {
5050
// Put the code you want to measure the time of here.
5151
}
5252
}
53-
53+
5454
}

0 commit comments

Comments
 (0)