Skip to content

Commit 3cc12cd

Browse files
authored
Merge pull request #297 from TaskarCenterAtUW/Bug-fixes
Bug fixes
2 parents c3bc4ab + f41cb99 commit 3cc12cd

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

GoInfoGame/GoInfoGame.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2916,7 +2916,7 @@
29162916
CODE_SIGN_ENTITLEMENTS = GoInfoGame/GoInfoGame.entitlements;
29172917
CODE_SIGN_IDENTITY = "Apple Development";
29182918
CODE_SIGN_STYLE = Automatic;
2919-
CURRENT_PROJECT_VERSION = 1;
2919+
CURRENT_PROJECT_VERSION = 2;
29202920
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
29212921
DEVELOPMENT_TEAM = G8MQVE5WWW;
29222922
ENABLE_USER_SCRIPT_SANDBOXING = NO;
@@ -2982,7 +2982,7 @@
29822982
CODE_SIGN_ENTITLEMENTS = GoInfoGame/GoInfoGame.entitlements;
29832983
CODE_SIGN_IDENTITY = "Apple Development";
29842984
CODE_SIGN_STYLE = Automatic;
2985-
CURRENT_PROJECT_VERSION = 1;
2985+
CURRENT_PROJECT_VERSION = 2;
29862986
DEVELOPMENT_TEAM = G8MQVE5WWW;
29872987
ENABLE_USER_SCRIPT_SANDBOXING = NO;
29882988
GENERATE_INFOPLIST_FILE = YES;

GoInfoGame/GoInfoGame/Network/APIEndPoint.swift

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,9 +127,15 @@ struct APIEndpoint {
127127
let header = [
128128
"Authorization": "Bearer \(accessToken)",
129129
"X-Workspace": workspaceId,
130-
"Content-Type": "application/xml"
130+
"Content-Type": "application/json"
131+
]
132+
let body = [
133+
"lat" : lat,
134+
"lon" : long,
135+
"text" : note
131136
]
132-
return APIEndpoint(path: "/notes?lat=\(lat)&lon=\(long)&text=\(note)", method: "POST", body: nil, headers: header, formData: nil)
137+
let jsonData = try? JSONSerialization.data(withJSONObject: body, options: [])
138+
return APIEndpoint(path: "/notes.json", method: "POST", body: jsonData, headers: header, formData: nil)
133139

134140
}
135141
}

0 commit comments

Comments
 (0)