Skip to content

Commit 849259b

Browse files
committed
Code style
Signed-off-by: Peter Friese <[email protected]>
1 parent e67c5ca commit 849259b

File tree

5 files changed

+15
-25
lines changed

5 files changed

+15
-25
lines changed

Examples/FriendlyFlix/app/FriendlyFlix/FriendlyFlix/App/FriendlyFlixApp.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ import Firebase
1616
import FirebaseAuth
1717
import FirebaseDataConnect
1818
import FriendlyFlixSDK
19-
import SwiftUI
2019
import os
20+
import SwiftUI
2121

2222
@main
2323
struct FriendlyFlixApp: App {
@@ -29,7 +29,7 @@ struct FriendlyFlixApp: App {
2929
/// To use the local emulator, go to the active scheme, and add `-useEmulator YES`
3030
/// to the _Arguments Passed On Launch_ section.
3131
public var useEmulator: Bool {
32-
let value = UserDefaults.standard.bool(forKey: "useEmulator")
32+
let value = UserDefaults.standard.bool(forKey: "useEmulator")
3333
logger.log("Using the emulator: \(value == true ? "YES" : "NO")")
3434
return value
3535
}
@@ -38,7 +38,7 @@ struct FriendlyFlixApp: App {
3838
FirebaseApp.configure()
3939
if useEmulator {
4040
DataConnect.friendlyFlixConnector.useEmulator(port: 9399)
41-
Auth.auth().useEmulator(withHost: "localhost", port:9099)
41+
Auth.auth().useEmulator(withHost: "localhost", port: 9099)
4242
}
4343

4444
authenticationService = AuthenticationService()

Examples/FriendlyFlix/app/FriendlyFlix/FriendlyFlix/Features/Authentication/AuthenticationScreen.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
// limitations under the License.
1414

1515
import AuthenticationServices
16-
import SwiftUI
1716
import os
17+
import SwiftUI
1818

1919
private enum FocusableField: Hashable {
2020
case email

Examples/FriendlyFlix/app/FriendlyFlix/FriendlyFlix/Features/Authentication/AuthenticationService.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,10 @@ class AuthenticationService {
6060
try await Auth.auth().createUser(withEmail: email, password: password)
6161

6262
if let onSignUp, let user = Auth.auth().currentUser {
63-
logger.debug("User signed in \(user.displayName ?? "(no fullname)") with email \(user.email ?? "(no email)")")
63+
logger
64+
.debug(
65+
"User signed in \(user.displayName ?? "(no fullname)") with email \(user.email ?? "(no email)")"
66+
)
6467
onSignUp(user)
6568
}
6669

Examples/FriendlyFlix/app/FriendlyFlix/FriendlyFlix/Features/Details/MovieCardView.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
import FirebaseDataConnect
1616
import FriendlyFlixSDK
1717
import NukeUI
18-
import SwiftUI
1918
import os
19+
import SwiftUI
2020

2121
struct MovieCardView: View {
2222
private let logger = Logger(subsystem: "FriendlyFlix", category: "moviecard")
@@ -34,6 +34,7 @@ struct MovieCardView: View {
3434
}
3535

3636
// MARK: - Favourite handling
37+
3738
private let isFavouriteRef: QueryRefObservation<
3839
GetIfFavoritedMovieQuery.Data,
3940
GetIfFavoritedMovieQuery.Variables

Examples/FriendlyFlix/app/FriendlyFlixSDK/Sources/FriendlyFlixOperations.swift

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,3 @@
1-
// Copyright 2024 Google LLC
2-
//
3-
// Licensed under the Apache License, Version 2.0 (the "License");
4-
// you may not use this file except in compliance with the License.
5-
// You may obtain a copy of the License at
6-
//
7-
// http://www.apache.org/licenses/LICENSE-2.0
8-
//
9-
// Unless required by applicable law or agreed to in writing, software
10-
// distributed under the License is distributed on an "AS IS" BASIS,
11-
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12-
// See the License for the specific language governing permissions and
13-
// limitations under the License.
14-
151
import Foundation
162

173
import FirebaseCore
@@ -700,7 +686,7 @@ public class ListMoviesQuery {
700686

701687
rating = try codecHelper.decode(Double?.self, forKey: .rating, container: &container)
702688

703-
tags = try codecHelper.decode([String].self, forKey: .tags, container: &container)
689+
tags = try codecHelper.decode([String]?.self, forKey: .tags, container: &container)
704690

705691
description = try codecHelper.decode(
706692
String?.self,
@@ -1087,7 +1073,7 @@ public class GetMovieByIdQuery {
10871073
container: &container
10881074
)
10891075

1090-
tags = try codecHelper.decode([String].self, forKey: .tags, container: &container)
1076+
tags = try codecHelper.decode([String]?.self, forKey: .tags, container: &container)
10911077

10921078
metadata = try codecHelper.decode(
10931079
[MovieMetadataMetadata].self,
@@ -1255,7 +1241,7 @@ public class GetActorByIdQuery {
12551241

12561242
genre = try codecHelper.decode(String?.self, forKey: .genre, container: &container)
12571243

1258-
tags = try codecHelper.decode([String].self, forKey: .tags, container: &container)
1244+
tags = try codecHelper.decode([String]?.self, forKey: .tags, container: &container)
12591245

12601246
imageUrl = try codecHelper.decode(String.self, forKey: .imageUrl, container: &container)
12611247
}
@@ -1316,7 +1302,7 @@ public class GetActorByIdQuery {
13161302

13171303
genre = try codecHelper.decode(String?.self, forKey: .genre, container: &container)
13181304

1319-
tags = try codecHelper.decode([String].self, forKey: .tags, container: &container)
1305+
tags = try codecHelper.decode([String]?.self, forKey: .tags, container: &container)
13201306

13211307
imageUrl = try codecHelper.decode(String.self, forKey: .imageUrl, container: &container)
13221308
}
@@ -1638,7 +1624,7 @@ public class GetCurrentUserQuery {
16381624
container: &container
16391625
)
16401626

1641-
tags = try codecHelper.decode([String].self, forKey: .tags, container: &container)
1627+
tags = try codecHelper.decode([String]?.self, forKey: .tags, container: &container)
16421628

16431629
metadata = try codecHelper.decode(
16441630
[MovieMetadataMetadata].self,

0 commit comments

Comments
 (0)