Skip to content

Commit b8c67d5

Browse files
mbrandonwactions-user
authored andcommitted
Run swift-format
1 parent a905fbf commit b8c67d5

File tree

12 files changed

+29
-27
lines changed

12 files changed

+29
-27
lines changed

Examples/CaseStudies/SwiftUICaseStudies/01-GettingStarted-Animations.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ let animationsReducer = Reducer<AnimationsState, AnimationsAction, AnimationsEnv
5151
: Effect(value: .setColor(color))
5252
.delay(for: 1, scheduler: environment.mainQueue)
5353
.eraseToEffect()
54-
}
54+
}
5555
)
5656

5757
case let .setColor(color):
@@ -105,7 +105,7 @@ struct AnimationsView: View {
105105
)
106106
.padding()
107107
Button("Rainbow") { viewStore.send(.rainbowButtonTapped) }
108-
.padding([.leading, .trailing, .bottom])
108+
.padding([.leading, .trailing, .bottom])
109109
}
110110
}
111111
}

Examples/CaseStudies/SwiftUICaseStudies/01-GettingStarted-Bindings-Basics.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,7 @@ struct BindingBasicsView: View {
7979

8080
Toggle(
8181
isOn: viewStore.binding(get: { $0.toggleIsOn }, send: BindingBasicsAction.toggleChange)
82-
)
83-
{
82+
) {
8483
Text("Disable other controls")
8584
}
8685

Examples/CaseStudies/SwiftUICaseStudies/04-HigherOrderReducers-Recursion.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ extension NestedState {
113113
children: [],
114114
id: UUID(),
115115
description: ""
116-
),
116+
)
117117
],
118118
id: UUID(),
119119
description: "Bar"

Examples/LocationManager/Common/AppCore.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -188,8 +188,7 @@ public let appReducer = Reducer<AppState, AppAction, AppEnvironment> { state, ac
188188
.signpost()
189189
.debug()
190190

191-
private let locationManagerReducer = Reducer<AppState, LocationManager.Action, AppEnvironment>
192-
{
191+
private let locationManagerReducer = Reducer<AppState, LocationManager.Action, AppEnvironment> {
193192
state, action, environment in
194193

195194
switch action {

Examples/MotionManager/MotionManager/MotionManagerView.swift

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,11 @@ let appReducer = Reducer<AppState, AppAction, AppEnvironment> { state, action, e
4949
return .none
5050

5151
case .motionUpdate(.failure):
52-
state.alert = .init(title: """
53-
We encountered a problem with the motion manager. Make sure you run this demo on a real \
54-
device, not the simulator.
55-
""")
52+
state.alert = .init(
53+
title: """
54+
We encountered a problem with the motion manager. Make sure you run this demo on a real \
55+
device, not the simulator.
56+
""")
5657
state.isRecording = false
5758
return .none
5859

Examples/SpeechRecognition/SpeechRecognition/SpeechRecognition.swift

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,10 @@ let appReducer = Reducer<AppState, AppAction, AppEnvironment> { state, action, e
8080
return .none
8181

8282
case .denied:
83-
state.alert = .init(title: """
84-
You denied access to speech recognition. This app needs access to transcribe your speech.
85-
""")
83+
state.alert = .init(
84+
title: """
85+
You denied access to speech recognition. This app needs access to transcribe your speech.
86+
""")
8687
return .none
8788

8889
case .restricted:

Examples/SpeechRecognition/SpeechRecognitionTests/SpeechRecognitionTests.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ class SpeechRecognitionTests: XCTestCase {
2828
.receive(.speechRecognizerAuthorizationStatusResponse(.denied)) {
2929
$0.alert = .init(
3030
title: """
31-
You denied access to speech recognition. This app needs access to transcribe your speech.
32-
"""
31+
You denied access to speech recognition. This app needs access to transcribe your speech.
32+
"""
3333
)
3434
$0.isRecording = false
3535
$0.speechRecognizerAuthorizationStatus = .denied

Examples/TicTacToe/Sources/Core/GameCore.swift

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,9 +93,11 @@ extension Array where Element == [Player?] {
9393
]
9494

9595
for condition in winConditions {
96-
let matches = condition
96+
let matches =
97+
condition
9798
.map { self[$0 % 3][$0 / 3] }
98-
let matchCount = matches
99+
let matchCount =
100+
matches
99101
.filter { $0 == player }
100102
.count
101103

Examples/Todos/TodosTests/TodosTests.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class TodosTests: XCTestCase {
3737
description: "",
3838
id: UUID(uuidString: "00000000-0000-0000-0000-000000000000")!,
3939
isComplete: false
40-
),
40+
)
4141
]
4242
)
4343
let store = TestStore(
@@ -160,7 +160,7 @@ class TodosTests: XCTestCase {
160160
store.assert(
161161
.send(.clearCompletedButtonTapped) {
162162
$0.todos = [
163-
$0.todos[0],
163+
$0.todos[0]
164164
]
165165
}
166166
)

Examples/VoiceMemos/VoiceMemosTests/VoiceMemosTests.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ class VoiceMemosTests: XCTestCase {
158158
mode: .notPlaying,
159159
title: "",
160160
url: URL(string: "https://www.pointfree.co/functions")!
161-
),
161+
)
162162
]
163163
),
164164
reducer: voiceMemosReducer,
@@ -206,7 +206,7 @@ class VoiceMemosTests: XCTestCase {
206206
mode: .notPlaying,
207207
title: "",
208208
url: URL(string: "https://www.pointfree.co/functions")!
209-
),
209+
)
210210
]
211211
),
212212
reducer: voiceMemosReducer,
@@ -241,7 +241,7 @@ class VoiceMemosTests: XCTestCase {
241241
mode: .playing(progress: 0.3),
242242
title: "",
243243
url: URL(string: "https://www.pointfree.co/functions")!
244-
),
244+
)
245245
]
246246
),
247247
reducer: voiceMemosReducer,
@@ -271,7 +271,7 @@ class VoiceMemosTests: XCTestCase {
271271
mode: .playing(progress: 0.3),
272272
title: "",
273273
url: URL(string: "https://www.pointfree.co/functions")!
274-
),
274+
)
275275
]
276276
),
277277
reducer: voiceMemosReducer,
@@ -297,7 +297,7 @@ class VoiceMemosTests: XCTestCase {
297297
mode: .notPlaying,
298298
title: "",
299299
url: URL(string: "https://www.pointfree.co/functions")!
300-
),
300+
)
301301
]
302302
),
303303
reducer: voiceMemosReducer,

0 commit comments

Comments
 (0)