payload: {"action":"created","comment":{"url":"https://api.github.com/repos/catcatherinezhao/tie/pulls/comments/304456221","pull_request_review_id":263105724,"id":304456221,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDMwNDQ1NjIyMQ==","diff_hunk":"@@ -82,18 +87,69 @@ tie.factory('SessionHistoryService', [\n       getSnapshotIndex: function() {\n         return data.snapshotIndex;\n       },\n+      /**\n+       * Returns the starter code, which has a snapshot index of 0.\n+       */\n+      getStarterCodeSnapshot: function() {\n+        var questionId = CurrentQuestionService.getCurrentQuestionId();\n+        localStorageKey = (\n+          LocalStorageKeyManagerService.getSessionHistoryKey(\n+            questionId, 0\n+          )\n+        );\n+        if (LocalStorageService.get(localStorageKey) === null) {\n+          throw Error('Cannot retrieve starter code from local storage.');\n+        } else {\n+          return LocalStorageService.get(\n+            localStorageKey)[0].feedbackParagraphDicts[0].content;\n+        }\n+      },\n       /**\n        * Returns the code from a previous snapshot.\n        */\n       getPreviousSnapshot: function(snapshotIndex) {\n+        if (snapshotIndex <= data.snapshotIndex) {","path":"client/question/services/SessionHistoryService.js","position":76,"original_position":50,"commit_id":"be8283d1bacdf2ca926393154bd4a9b4c574df4b","original_commit_id":"92f957ff22378066e6de2b1b8e80cc5c9e9f99ba","user":{"login":"eyurko","id":3400725,"node_id":"MDQ6VXNlcjM0MDA3MjU=","avatar_url":"https://avatars1.githubusercontent.com/u/3400725?v=4","gravatar_id":"","url":"https://api.github.com/users/eyurko","html_url":"https://github.com/eyurko","followers_url":"https://api.github.com/users/eyurko/followers","following_url":"https://api.github.com/users/eyurko/following{/other_user}","gists_url":"https://api.github.com/users/eyurko/gists{/gist_id}","starred_url":"https://api.github.com/users/eyurko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eyurko/subscriptions","organizations_url":"https://api.github.com/users/eyurko/orgs","repos_url":"https://api.github.com/users/eyurko/repos","events_url":"https://api.github.com/users/eyurko/events{/privacy}","received_events_url":"https://api.github.com/users/eyurko/received_events","type":"User","site_admin":false},"body":"What if snapshotIndex is negative?","created_at":"2019-07-17T15:01:32Z","updated_at":"2019-07-17T15:01:59Z","html_url":"https://github.com/catcatherinezhao/tie/pull/3#discussion_r304456221","pull_request_url":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/catcatherinezhao/tie/pulls/comments/304456221"},"html":{"href":"https://github.com/catcatherinezhao/tie/pull/3#discussion_r304456221"},"pull_request":{"href":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3","id":292982685,"node_id":"MDExOlB1bGxSZXF1ZXN0MjkyOTgyNjg1","html_url":"https://github.com/catcatherinezhao/tie/pull/3","diff_url":"https://github.com/catcatherinezhao/tie/pull/3.diff","patch_url":"https://github.com/catcatherinezhao/tie/pull/3.patch","issue_url":"https://api.github.com/repos/catcatherinezhao/tie/issues/3","number":3,"state":"open","locked":false,"title":"Ux updates buttons","user":{"login":"catcatherinezhao","id":33742804,"node_id":"MDQ6VXNlcjMzNzQyODA0","avatar_url":"https://avatars2.githubusercontent.com/u/33742804?v=4","gravatar_id":"","url":"https://api.github.com/users/catcatherinezhao","html_url":"https://github.com/catcatherinezhao","followers_url":"https://api.github.com/users/catcatherinezhao/followers","following_url":"https://api.github.com/users/catcatherinezhao/following{/other_user}","gists_url":"https://api.github.com/users/catcatherinezhao/gists{/gist_id}","starred_url":"https://api.github.com/users/catcatherinezhao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/catcatherinezhao/subscriptions","organizations_url":"https://api.github.com/users/catcatherinezhao/orgs","repos_url":"https://api.github.com/users/catcatherinezhao/repos","events_url":"https://api.github.com/users/catcatherinezhao/events{/privacy}","received_events_url":"https://api.github.com/users/catcatherinezhao/received_events","type":"User","site_admin":false},"body":"Created one new button (step through) and one new drop down menu (previous). Deleted primer link and language label and corresponding tests. Deleted start over button and corresponding tests.","created_at":"2019-06-28T22:11:12Z","updated_at":"2019-07-17T15:01:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e0cd7ee9bf74f0e1c322a24b65a720d0e5d2b031","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3/commits","review_comments_url":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3/comments","review_comment_url":"https://api.github.com/repos/catcatherinezhao/tie/pulls/comments{/number}","comments_url":"https://api.github.com/repos/catcatherinezhao/tie/issues/3/comments","statuses_url":"https://api.github.com/repos/catcatherinezhao/tie/statuses/be8283d1bacdf2ca926393154bd4a9b4c574df4b","head":{"label":"catcatherinezhao:ux-updates-buttons","ref":"ux-updates-buttons","sha":"be8283d1bacdf2ca926393154bd4a9b4c574df4b","user":{"login":"catcatherinezhao","id":33742804,"node_id":"MDQ6VXNlcjMzNzQyODA0","avatar_url":"https://avatars2.githubusercontent.com/u/33742804?v=4","gravatar_id":"","url":"https://api.github.com/users/catcatherinezhao","html_url":"https://github.com/catcatherinezhao","followers_url":"https://api.github.com/users/catcatherinezhao/followers","following_url":"https://api.github.com/users/catcatherinezhao/following{/other_user}","gists_url":"https://api.github.com/users/catcatherinezhao/gists{/gist_id}","starred_url":"https://api.github.com/users/catcatherinezhao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/catcatherinezhao/subscriptions","organizations_url":"https://api.github.com/users/catcatherinezhao/orgs","repos_url":"https://api.github.com/users/catcatherinezhao/repos","events_url":"https://api.github.com/users/catcatherinezhao/events{/privacy}","received_events_url":"https://api.github.com/users/catcatherinezhao/received_events","type":"User","site_admin":false},"repo":{"id":193753536,"node_id":"MDEwOlJlcG9zaXRvcnkxOTM3NTM1MzY=","name":"tie","full_name":"catcatherinezhao/tie","private":false,"owner":{"login":"catcatherinezhao","id":33742804,"node_id":"MDQ6VXNlcjMzNzQyODA0","avatar_url":"https://avatars2.githubusercontent.com/u/33742804?v=4","gravatar_id":"","url":"https://api.github.com/users/catcatherinezhao","html_url":"https://github.com/catcatherinezhao","followers_url":"https://api.github.com/users/catcatherinezhao/followers","following_url":"https://api.github.com/users/catcatherinezhao/following{/other_user}","gists_url":"https://api.github.com/users/catcatherinezhao/gists{/gist_id}","starred_url":"https://api.github.com/users/catcatherinezhao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/catcatherinezhao/subscriptions","organizations_url":"https://api.github.com/users/catcatherinezhao/orgs","repos_url":"https://api.github.com/users/catcatherinezhao/repos","events_url":"https://api.github.com/users/catcatherinezhao/events{/privacy}","received_events_url":"https://api.github.com/users/catcatherinezhao/received_events","type":"User","site_admin":false},"html_url":"https://github.com/catcatherinezhao/tie","description":null,"fork":true,"url":"https://api.github.com/repos/catcatherinezhao/tie","forks_url":"https://api.github.com/repos/catcatherinezhao/tie/forks","keys_url":"https://api.github.com/repos/catcatherinezhao/tie/keys{/key_id}","collaborators_url":"https://api.github.com/repos/catcatherinezhao/tie/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/catcatherinezhao/tie/teams","hooks_url":"https://api.github.com/repos/catcatherinezhao/tie/hooks","issue_events_url":"https://api.github.com/repos/catcatherinezhao/tie/issues/events{/number}","events_url":"https://api.github.com/repos/catcatherinezhao/tie/events","assignees_url":"https://api.github.com/repos/catcatherinezhao/tie/assignees{/user}","branches_url":"https://api.github.com/repos/catcatherinezhao/tie/branches{/branch}","tags_url":"https://api.github.com/repos/catcatherinezhao/tie/tags","blobs_url":"https://api.github.com/repos/catcatherinezhao/tie/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/catcatherinezhao/tie/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/catcatherinezhao/tie/git/refs{/sha}","trees_url":"https://api.github.com/repos/catcatherinezhao/tie/git/trees{/sha}","statuses_url":"https://api.github.com/repos/catcatherinezhao/tie/statuses/{sha}","languages_url":"https://api.github.com/repos/catcatherinezhao/tie/languages","stargazers_url":"https://api.github.com/repos/catcatherinezhao/tie/stargazers","contributors_url":"https://api.github.com/repos/catcatherinezhao/tie/contributors","subscribers_url":"https://api.github.com/repos/catcatherinezhao/tie/subscribers","subscription_url":"https://api.github.com/repos/catcatherinezhao/tie/subscription","commits_url":"https://api.github.com/repos/catcatherinezhao/tie/commits{/sha}","git_commits_url":"https://api.github.com/repos/catcatherinezhao/tie/git/commits{/sha}","comments_url":"https://api.github.com/repos/catcatherinezhao/tie/comments{/number}","issue_comment_url":"https://api.github.com/repos/catcatherinezhao/tie/issues/comments{/number}","contents_url":"https://api.github.com/repos/catcatherinezhao/tie/contents/{+path}","compare_url":"https://api.github.com/repos/catcatherinezhao/tie/compare/{base}...{head}","merges_url":"https://api.github.com/repos/catcatherinezhao/tie/merges","archive_url":"https://api.github.com/repos/catcatherinezhao/tie/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/catcatherinezhao/tie/downloads","issues_url":"https://api.github.com/repos/catcatherinezhao/tie/issues{/number}","pulls_url":"https://api.github.com/repos/catcatherinezhao/tie/pulls{/number}","milestones_url":"https://api.github.com/repos/catcatherinezhao/tie/milestones{/number}","notifications_url":"https://api.github.com/repos/catcatherinezhao/tie/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/catcatherinezhao/tie/labels{/name}","releases_url":"https://api.github.com/repos/catcatherinezhao/tie/releases{/id}","deployments_url":"https://api.github.com/repos/catcatherinezhao/tie/deployments","created_at":"2019-06-25T17:28:23Z","updated_at":"2019-06-28T21:59:59Z","pushed_at":"2019-07-16T23:44:47Z","git_url":"git://github.com/catcatherinezhao/tie.git","ssh_url":"git@github.com:catcatherinezhao/tie.git","clone_url":"https://github.com/catcatherinezhao/tie.git","svn_url":"https://github.com/catcatherinezhao/tie","homepage":null,"size":10808,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"disabled":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":0,"default_branch":"master"}},"base":{"label":"catcatherinezhao:master","ref":"master","sha":"e6464e1832a265a06ea7c4ee8e6e6753305d4a95","user":{"login":"catcatherinezhao","id":33742804,"node_id":"MDQ6VXNlcjMzNzQyODA0","avatar_url":"https://avatars2.githubusercontent.com/u/33742804?v=4","gravatar_id":"","url":"https://api.github.com/users/catcatherinezhao","html_url":"https://github.com/catcatherinezhao","followers_url":"https://api.github.com/users/catcatherinezhao/followers","following_url":"https://api.github.com/users/catcatherinezhao/following{/other_user}","gists_url":"https://api.github.com/users/catcatherinezhao/gists{/gist_id}","starred_url":"https://api.github.com/users/catcatherinezhao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/catcatherinezhao/subscriptions","organizations_url":"https://api.github.com/users/catcatherinezhao/orgs","repos_url":"https://api.github.com/users/catcatherinezhao/repos","events_url":"https://api.github.com/users/catcatherinezhao/events{/privacy}","received_events_url":"https://api.github.com/users/catcatherinezhao/received_events","type":"User","site_admin":false},"repo":{"id":193753536,"node_id":"MDEwOlJlcG9zaXRvcnkxOTM3NTM1MzY=","name":"tie","full_name":"catcatherinezhao/tie","private":false,"owner":{"login":"catcatherinezhao","id":33742804,"node_id":"MDQ6VXNlcjMzNzQyODA0","avatar_url":"https://avatars2.githubusercontent.com/u/33742804?v=4","gravatar_id":"","url":"https://api.github.com/users/catcatherinezhao","html_url":"https://github.com/catcatherinezhao","followers_url":"https://api.github.com/users/catcatherinezhao/followers","following_url":"https://api.github.com/users/catcatherinezhao/following{/other_user}","gists_url":"https://api.github.com/users/catcatherinezhao/gists{/gist_id}","starred_url":"https://api.github.com/users/catcatherinezhao/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/catcatherinezhao/subscriptions","organizations_url":"https://api.github.com/users/catcatherinezhao/orgs","repos_url":"https://api.github.com/users/catcatherinezhao/repos","events_url":"https://api.github.com/users/catcatherinezhao/events{/privacy}","received_events_url":"https://api.github.com/users/catcatherinezhao/received_events","type":"User","site_admin":false},"html_url":"https://github.com/catcatherinezhao/tie","description":null,"fork":true,"url":"https://api.github.com/repos/catcatherinezhao/tie","forks_url":"https://api.github.com/repos/catcatherinezhao/tie/forks","keys_url":"https://api.github.com/repos/catcatherinezhao/tie/keys{/key_id}","collaborators_url":"https://api.github.com/repos/catcatherinezhao/tie/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/catcatherinezhao/tie/teams","hooks_url":"https://api.github.com/repos/catcatherinezhao/tie/hooks","issue_events_url":"https://api.github.com/repos/catcatherinezhao/tie/issues/events{/number}","events_url":"https://api.github.com/repos/catcatherinezhao/tie/events","assignees_url":"https://api.github.com/repos/catcatherinezhao/tie/assignees{/user}","branches_url":"https://api.github.com/repos/catcatherinezhao/tie/branches{/branch}","tags_url":"https://api.github.com/repos/catcatherinezhao/tie/tags","blobs_url":"https://api.github.com/repos/catcatherinezhao/tie/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/catcatherinezhao/tie/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/catcatherinezhao/tie/git/refs{/sha}","trees_url":"https://api.github.com/repos/catcatherinezhao/tie/git/trees{/sha}","statuses_url":"https://api.github.com/repos/catcatherinezhao/tie/statuses/{sha}","languages_url":"https://api.github.com/repos/catcatherinezhao/tie/languages","stargazers_url":"https://api.github.com/repos/catcatherinezhao/tie/stargazers","contributors_url":"https://api.github.com/repos/catcatherinezhao/tie/contributors","subscribers_url":"https://api.github.com/repos/catcatherinezhao/tie/subscribers","subscription_url":"https://api.github.com/repos/catcatherinezhao/tie/subscription","commits_url":"https://api.github.com/repos/catcatherinezhao/tie/commits{/sha}","git_commits_url":"https://api.github.com/repos/catcatherinezhao/tie/git/commits{/sha}","comments_url":"https://api.github.com/repos/catcatherinezhao/tie/comments{/number}","issue_comment_url":"https://api.github.com/repos/catcatherinezhao/tie/issues/comments{/number}","contents_url":"https://api.github.com/repos/catcatherinezhao/tie/contents/{+path}","compare_url":"https://api.github.com/repos/catcatherinezhao/tie/compare/{base}...{head}","merges_url":"https://api.github.com/repos/catcatherinezhao/tie/merges","archive_url":"https://api.github.com/repos/catcatherinezhao/tie/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/catcatherinezhao/tie/downloads","issues_url":"https://api.github.com/repos/catcatherinezhao/tie/issues{/number}","pulls_url":"https://api.github.com/repos/catcatherinezhao/tie/pulls{/number}","milestones_url":"https://api.github.com/repos/catcatherinezhao/tie/milestones{/number}","notifications_url":"https://api.github.com/repos/catcatherinezhao/tie/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/catcatherinezhao/tie/labels{/name}","releases_url":"https://api.github.com/repos/catcatherinezhao/tie/releases{/id}","deployments_url":"https://api.github.com/repos/catcatherinezhao/tie/deployments","created_at":"2019-06-25T17:28:23Z","updated_at":"2019-06-28T21:59:59Z","pushed_at":"2019-07-16T23:44:47Z","git_url":"git://github.com/catcatherinezhao/tie.git","ssh_url":"git@github.com:catcatherinezhao/tie.git","clone_url":"https://github.com/catcatherinezhao/tie.git","svn_url":"https://github.com/catcatherinezhao/tie","homepage":null,"size":10808,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"disabled":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":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3"},"html":{"href":"https://github.com/catcatherinezhao/tie/pull/3"},"issue":{"href":"https://api.github.com/repos/catcatherinezhao/tie/issues/3"},"comments":{"href":"https://api.github.com/repos/catcatherinezhao/tie/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/catcatherinezhao/tie/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/catcatherinezhao/tie/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/catcatherinezhao/tie/statuses/be8283d1bacdf2ca926393154bd4a9b4c574df4b"}},"author_association":"OWNER"}}
other: {"actor":{"display_login":"eyurko"}}