{"action":"created","comment":{"url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/comments/255683630","pull_request_review_id":202325958,"id":255683630,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI1NTY4MzYzMA==","diff_hunk":"@@ -28,43 +28,71 @@\n     private static final String KEY_STARTED = \"started\";\n \n     private Utils() {\n+\n     }\n \n-    static PilgrimUserInfo fromMap(Map<String, ?> map) {\n-        if (map.isEmpty()) {\n+    static String jsonFromUserInfo(@NonNull PilgrimUserInfo userInfo) {\n+        JSONArray keys = new JSONArray();\n+        JSONArray values = new JSONArray();\n+\n+        for (Map.Entry<String, String> entry : userInfo.entrySet()) {\n+            keys.put(entry.getKey());\n+            values.put(entry.getValue());\n+        }\n+\n+        try {\n+            JSONObject json = new JSONObject();\n+            json.put(\"keys\", keys);\n+            json.put(\"values\", values);\n+            return json.toString();\n+        } catch (JSONException e) {\n             return null;\n         }\n+    }\n+\n+    static PilgrimUserInfo userInfoFromJSON(@NonNull String jsonString) {","path":"source/android-source/pilgrimunitysdk/src/main/java/com/foursquare/pilgrimunitysdk/Utils.java","position":28,"original_position":28,"commit_id":"12e3de412a2696729165c5830f8a5df96637d841","original_commit_id":"12e3de412a2696729165c5830f8a5df96637d841","user":{"login":"kylefowler","id":818067,"node_id":"MDQ6VXNlcjgxODA2Nw==","avatar_url":"https://avatars0.githubusercontent.com/u/818067?v=4","gravatar_id":"","url":"https://api.github.com/users/kylefowler","html_url":"https://github.com/kylefowler","followers_url":"https://api.github.com/users/kylefowler/followers","following_url":"https://api.github.com/users/kylefowler/following{/other_user}","gists_url":"https://api.github.com/users/kylefowler/gists{/gist_id}","starred_url":"https://api.github.com/users/kylefowler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylefowler/subscriptions","organizations_url":"https://api.github.com/users/kylefowler/orgs","repos_url":"https://api.github.com/users/kylefowler/repos","events_url":"https://api.github.com/users/kylefowler/events{/privacy}","received_events_url":"https://api.github.com/users/kylefowler/received_events","type":"User","site_admin":false},"body":"yeah, comment was just that you would no longer have \"keys\" and \"values\" array. It would just be to loop through the keys in the `json` object directly.","created_at":"2019-02-11T20:39:56Z","updated_at":"2019-02-11T20:39:57Z","html_url":"https://github.com/foursquare/pilgrim-unity-sdk/pull/4#discussion_r255683630","pull_request_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/comments/255683630"},"html":{"href":"https://github.com/foursquare/pilgrim-unity-sdk/pull/4#discussion_r255683630"},"pull_request":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4"}},"in_reply_to_id":255667128},"pull_request":{"url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4","id":252033198,"node_id":"MDExOlB1bGxSZXF1ZXN0MjUyMDMzMTk4","html_url":"https://github.com/foursquare/pilgrim-unity-sdk/pull/4","diff_url":"https://github.com/foursquare/pilgrim-unity-sdk/pull/4.diff","patch_url":"https://github.com/foursquare/pilgrim-unity-sdk/pull/4.patch","issue_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/4","number":4,"state":"open","locked":false,"title":"Get user info and user info serialization cleanup","user":{"login":"marchinram","id":197929,"node_id":"MDQ6VXNlcjE5NzkyOQ==","avatar_url":"https://avatars2.githubusercontent.com/u/197929?v=4","gravatar_id":"","url":"https://api.github.com/users/marchinram","html_url":"https://github.com/marchinram","followers_url":"https://api.github.com/users/marchinram/followers","following_url":"https://api.github.com/users/marchinram/following{/other_user}","gists_url":"https://api.github.com/users/marchinram/gists{/gist_id}","starred_url":"https://api.github.com/users/marchinram/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marchinram/subscriptions","organizations_url":"https://api.github.com/users/marchinram/orgs","repos_url":"https://api.github.com/users/marchinram/repos","events_url":"https://api.github.com/users/marchinram/events{/privacy}","received_events_url":"https://api.github.com/users/marchinram/received_events","type":"User","site_admin":false},"body":"Added `PilgrimUnitySDK.GetUserInfo()` method and cleaned up the way the user info object is serialized and deserialized using `ISerializationCallbackReceiver`","created_at":"2019-02-11T19:21:21Z","updated_at":"2019-02-11T20:39:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"78e36912ebd296681707822ae76d1d407aebf4b7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4/commits","review_comments_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4/comments","review_comment_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/comments{/number}","comments_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/4/comments","statuses_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/statuses/12e3de412a2696729165c5830f8a5df96637d841","head":{"label":"foursquare:feature/get-user-info","ref":"feature/get-user-info","sha":"12e3de412a2696729165c5830f8a5df96637d841","user":{"login":"foursquare","id":72779,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNzc5","avatar_url":"https://avatars1.githubusercontent.com/u/72779?v=4","gravatar_id":"","url":"https://api.github.com/users/foursquare","html_url":"https://github.com/foursquare","followers_url":"https://api.github.com/users/foursquare/followers","following_url":"https://api.github.com/users/foursquare/following{/other_user}","gists_url":"https://api.github.com/users/foursquare/gists{/gist_id}","starred_url":"https://api.github.com/users/foursquare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foursquare/subscriptions","organizations_url":"https://api.github.com/users/foursquare/orgs","repos_url":"https://api.github.com/users/foursquare/repos","events_url":"https://api.github.com/users/foursquare/events{/privacy}","received_events_url":"https://api.github.com/users/foursquare/received_events","type":"Organization","site_admin":false},"repo":{"id":145758377,"node_id":"MDEwOlJlcG9zaXRvcnkxNDU3NTgzNzc=","name":"pilgrim-unity-sdk","full_name":"foursquare/pilgrim-unity-sdk","private":false,"owner":{"login":"foursquare","id":72779,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNzc5","avatar_url":"https://avatars1.githubusercontent.com/u/72779?v=4","gravatar_id":"","url":"https://api.github.com/users/foursquare","html_url":"https://github.com/foursquare","followers_url":"https://api.github.com/users/foursquare/followers","following_url":"https://api.github.com/users/foursquare/following{/other_user}","gists_url":"https://api.github.com/users/foursquare/gists{/gist_id}","starred_url":"https://api.github.com/users/foursquare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foursquare/subscriptions","organizations_url":"https://api.github.com/users/foursquare/orgs","repos_url":"https://api.github.com/users/foursquare/repos","events_url":"https://api.github.com/users/foursquare/events{/privacy}","received_events_url":"https://api.github.com/users/foursquare/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/foursquare/pilgrim-unity-sdk","description":"Unity package which enables easy integration with Pilgrim SDK","fork":false,"url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk","forks_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/forks","keys_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/keys{/key_id}","collaborators_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/teams","hooks_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/hooks","issue_events_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/events{/number}","events_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/events","assignees_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/assignees{/user}","branches_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/branches{/branch}","tags_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/tags","blobs_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/refs{/sha}","trees_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/trees{/sha}","statuses_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/statuses/{sha}","languages_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/languages","stargazers_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/stargazers","contributors_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/contributors","subscribers_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/subscribers","subscription_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/subscription","commits_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/commits{/sha}","git_commits_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/commits{/sha}","comments_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/comments{/number}","issue_comment_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/comments{/number}","contents_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/contents/{+path}","compare_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/compare/{base}...{head}","merges_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/merges","archive_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/downloads","issues_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues{/number}","pulls_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls{/number}","milestones_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/milestones{/number}","notifications_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/labels{/name}","releases_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/releases{/id}","deployments_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/deployments","created_at":"2018-08-22T20:18:39Z","updated_at":"2019-02-11T20:25:17Z","pushed_at":"2019-02-11T20:25:18Z","git_url":"git://github.com/foursquare/pilgrim-unity-sdk.git","ssh_url":"git@github.com:foursquare/pilgrim-unity-sdk.git","clone_url":"https://github.com/foursquare/pilgrim-unity-sdk.git","svn_url":"https://github.com/foursquare/pilgrim-unity-sdk","homepage":"","size":90403,"stargazers_count":1,"watchers_count":1,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"foursquare:master","ref":"master","sha":"0761f09c95f0b6969efbfa1901293a86906d5a7a","user":{"login":"foursquare","id":72779,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNzc5","avatar_url":"https://avatars1.githubusercontent.com/u/72779?v=4","gravatar_id":"","url":"https://api.github.com/users/foursquare","html_url":"https://github.com/foursquare","followers_url":"https://api.github.com/users/foursquare/followers","following_url":"https://api.github.com/users/foursquare/following{/other_user}","gists_url":"https://api.github.com/users/foursquare/gists{/gist_id}","starred_url":"https://api.github.com/users/foursquare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foursquare/subscriptions","organizations_url":"https://api.github.com/users/foursquare/orgs","repos_url":"https://api.github.com/users/foursquare/repos","events_url":"https://api.github.com/users/foursquare/events{/privacy}","received_events_url":"https://api.github.com/users/foursquare/received_events","type":"Organization","site_admin":false},"repo":{"id":145758377,"node_id":"MDEwOlJlcG9zaXRvcnkxNDU3NTgzNzc=","name":"pilgrim-unity-sdk","full_name":"foursquare/pilgrim-unity-sdk","private":false,"owner":{"login":"foursquare","id":72779,"node_id":"MDEyOk9yZ2FuaXphdGlvbjcyNzc5","avatar_url":"https://avatars1.githubusercontent.com/u/72779?v=4","gravatar_id":"","url":"https://api.github.com/users/foursquare","html_url":"https://github.com/foursquare","followers_url":"https://api.github.com/users/foursquare/followers","following_url":"https://api.github.com/users/foursquare/following{/other_user}","gists_url":"https://api.github.com/users/foursquare/gists{/gist_id}","starred_url":"https://api.github.com/users/foursquare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foursquare/subscriptions","organizations_url":"https://api.github.com/users/foursquare/orgs","repos_url":"https://api.github.com/users/foursquare/repos","events_url":"https://api.github.com/users/foursquare/events{/privacy}","received_events_url":"https://api.github.com/users/foursquare/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/foursquare/pilgrim-unity-sdk","description":"Unity package which enables easy integration with Pilgrim SDK","fork":false,"url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk","forks_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/forks","keys_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/keys{/key_id}","collaborators_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/teams","hooks_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/hooks","issue_events_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/events{/number}","events_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/events","assignees_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/assignees{/user}","branches_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/branches{/branch}","tags_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/tags","blobs_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/refs{/sha}","trees_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/trees{/sha}","statuses_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/statuses/{sha}","languages_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/languages","stargazers_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/stargazers","contributors_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/contributors","subscribers_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/subscribers","subscription_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/subscription","commits_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/commits{/sha}","git_commits_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/git/commits{/sha}","comments_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/comments{/number}","issue_comment_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/comments{/number}","contents_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/contents/{+path}","compare_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/compare/{base}...{head}","merges_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/merges","archive_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/downloads","issues_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues{/number}","pulls_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls{/number}","milestones_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/milestones{/number}","notifications_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/labels{/name}","releases_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/releases{/id}","deployments_url":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/deployments","created_at":"2018-08-22T20:18:39Z","updated_at":"2019-02-11T20:25:17Z","pushed_at":"2019-02-11T20:25:18Z","git_url":"git://github.com/foursquare/pilgrim-unity-sdk.git","ssh_url":"git@github.com:foursquare/pilgrim-unity-sdk.git","clone_url":"https://github.com/foursquare/pilgrim-unity-sdk.git","svn_url":"https://github.com/foursquare/pilgrim-unity-sdk","homepage":"","size":90403,"stargazers_count":1,"watchers_count":1,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4"},"html":{"href":"https://github.com/foursquare/pilgrim-unity-sdk/pull/4"},"issue":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/4"},"comments":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/foursquare/pilgrim-unity-sdk/statuses/12e3de412a2696729165c5830f8a5df96637d841"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"kylefowler"}}