Skip to content

Commit 223757b

Browse files
committed
nits
1 parent 27340cf commit 223757b

File tree

2 files changed

+1
-26
lines changed

2 files changed

+1
-26
lines changed

ParseSwift.playground/Pages/4 - User - Continued.xcplaygroundpage/Contents.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ User.current?.save { results in
5959

6060
switch results {
6161
case .success(let updatedUser):
62-
print("Successfully save myCustomKey and score to ParseServer: \(updatedUser)")
62+
print("Successfully save custom fields of User to ParseServer: \(updatedUser)")
6363
case .failure(let error):
6464
print("Failed to update user: \(error)")
6565
}

ParseSwift.playground/Pages/6 - Installation.xcplaygroundpage/Contents.swift

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -29,29 +29,6 @@ struct Installation: ParseInstallation {
2929

3030
//: Your custom keys
3131
var customKey: String?
32-
var score: GameScore?
33-
var targetScore: GameScore?
34-
}
35-
36-
//: Create your own value typed `ParseObject`.
37-
struct GameScore: ParseObject {
38-
//: Those are required for Object
39-
var objectId: String?
40-
var createdAt: Date?
41-
var updatedAt: Date?
42-
var ACL: ParseACL?
43-
44-
//: Your own properties.
45-
var score: Int? = 0
46-
47-
//: Custom initializer.
48-
init(score: Int) {
49-
self.score = score
50-
}
51-
52-
init(objectId: String?) {
53-
self.objectId = objectId
54-
}
5532
}
5633

5734
//: WARNING: All calls on Installation need to be done on the main queue
@@ -63,8 +40,6 @@ DispatchQueue.main.async {
6340
returns to main queue.
6441
*/
6542
Installation.current?.customKey = "myCustomInstallationKey2"
66-
Installation.current?.score = GameScore(score: 12)
67-
Installation.current?.targetScore = GameScore(score: 100)
6843
Installation.current?.save { results in
6944

7045
switch results {

0 commit comments

Comments
 (0)