{"action":"created","comment":{"url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/comments/33919130","id":33919130,"diff_hunk":"@@ -482,18 +486,26 @@ function (\n \n     /**\n      * Sets a UUID value that is unrelated to any account information.\n-     * This value is useful to determine if the logged out user qualifies for ab testing or metrics.\n+     * This value is useful to determine if the logged out user qualifies\n+     * for A/B testing or metrics.\n      */\n     initializeUuid: function () {\n       var storage = Storage.factory('localStorage', this._window);\n \n-      // we reuse the same uuid if it is available in local storage.\n-      if (storage.get('uuid')) {\n+      // Reuse the same uuid if it is available in local storage.\n+      if (this._searchParam('resume')) {\n+        var resumeParam = this._searchParam('resume');\n+        var resumeToken = new ResumeToken(ResumeToken.parse(resumeParam));","path":"app/scripts/lib/app-start.js","position":52,"original_position":52,"commit_id":"1f267956b752721b49f08cddfa4ce60355dba921","original_commit_id":"1f267956b752721b49f08cddfa4ce60355dba921","user":{"login":"shane-tomlinson","id":848085,"avatar_url":"https://avatars.githubusercontent.com/u/848085?v=3","gravatar_id":"","url":"https://api.github.com/users/shane-tomlinson","html_url":"https://github.com/shane-tomlinson","followers_url":"https://api.github.com/users/shane-tomlinson/followers","following_url":"https://api.github.com/users/shane-tomlinson/following{/other_user}","gists_url":"https://api.github.com/users/shane-tomlinson/gists{/gist_id}","starred_url":"https://api.github.com/users/shane-tomlinson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shane-tomlinson/subscriptions","organizations_url":"https://api.github.com/users/shane-tomlinson/orgs","repos_url":"https://api.github.com/users/shane-tomlinson/repos","events_url":"https://api.github.com/users/shane-tomlinson/events{/privacy}","received_events_url":"https://api.github.com/users/shane-tomlinson/received_events","type":"User","site_admin":false},"body":"See [this comment](https://github.com/mozilla/fxa-content-server/pull/2688/files#r33918999) about moving the creation logic to a static function on ResumeToken.","created_at":"2015-07-06T09:44:00Z","updated_at":"2015-07-06T09:44:00Z","html_url":"https://github.com/mozilla/fxa-content-server/pull/2688#discussion_r33919130","pull_request_url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688","_links":{"self":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/comments/33919130"},"html":{"href":"https://github.com/mozilla/fxa-content-server/pull/2688#discussion_r33919130"},"pull_request":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688"}}},"pull_request":{"url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688","id":39221811,"html_url":"https://github.com/mozilla/fxa-content-server/pull/2688","diff_url":"https://github.com/mozilla/fxa-content-server/pull/2688.diff","patch_url":"https://github.com/mozilla/fxa-content-server/pull/2688.patch","issue_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues/2688","number":2688,"state":"open","locked":false,"title":"WIP: tie together signup & verification metrics.","user":{"login":"shane-tomlinson","id":848085,"avatar_url":"https://avatars.githubusercontent.com/u/848085?v=3","gravatar_id":"","url":"https://api.github.com/users/shane-tomlinson","html_url":"https://github.com/shane-tomlinson","followers_url":"https://api.github.com/users/shane-tomlinson/followers","following_url":"https://api.github.com/users/shane-tomlinson/following{/other_user}","gists_url":"https://api.github.com/users/shane-tomlinson/gists{/gist_id}","starred_url":"https://api.github.com/users/shane-tomlinson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shane-tomlinson/subscriptions","organizations_url":"https://api.github.com/users/shane-tomlinson/orgs","repos_url":"https://api.github.com/users/shane-tomlinson/repos","events_url":"https://api.github.com/users/shane-tomlinson/events{/privacy}","received_events_url":"https://api.github.com/users/shane-tomlinson/received_events","type":"User","site_admin":false},"body":"This is made of two commits:\r\n-----------------\r\nfeat(client): `campaign` and `entrypoint` are sent to metrics on verification.\r\n\r\n* Pass the `campaign` and `entrypoint` to the verification page via the ResumeToken.\r\n* Push down resume token handling from the oauth relier to the base relier\r\n  so that it can be shared.\r\n* The base relier always passes `campaign` and `entrypoint`\r\n\r\nissue #2491, #2101\r\n\r\n-----------------\r\nfeat(client): Save the `uuid` to the ResumeToken, re-populate it on startup.\r\n\r\n* Save a `uuid` onto the User model.\r\n* Extract ResumeToken related functionality from the relier to a model mixin,\r\n  models/mixin/resume-token.js.\r\n* Add `uuid` to the list of fields that can be saved into the ResumeToken\r\n* Re-populate the `uuid` from the resume query param if its not already in localStorage.\r\n\r\nfixes #2491\r\n\r\n-------------------\r\n\r\n@rfk and @vladikoff - r?\r\n\r\nI think this should do it. @vladikoff - I added the `uuid` to the User model since I suggested it in your [mailcheck PR](https://github.com/mozilla/fxa-content-server/pull/2456#discussion_r33894534) and I was trying to get that information passed across already.\r\n","created_at":"2015-07-05T14:40:53Z","updated_at":"2015-07-06T09:44:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9ea11d57d7cf653174efc2d1550513120c12206f","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688/commits","review_comments_url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688/comments","review_comment_url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues/2688/comments","statuses_url":"https://api.github.com/repos/mozilla/fxa-content-server/statuses/1f267956b752721b49f08cddfa4ce60355dba921","head":{"label":"mozilla:issue-2491-campaign-entrypoint-verification","ref":"issue-2491-campaign-entrypoint-verification","sha":"1f267956b752721b49f08cddfa4ce60355dba921","user":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":11778024,"name":"fxa-content-server","full_name":"mozilla/fxa-content-server","owner":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/fxa-content-server","description":"Firefox Accounts Content Server","fork":false,"url":"https://api.github.com/repos/mozilla/fxa-content-server","forks_url":"https://api.github.com/repos/mozilla/fxa-content-server/forks","keys_url":"https://api.github.com/repos/mozilla/fxa-content-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/fxa-content-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/fxa-content-server/teams","hooks_url":"https://api.github.com/repos/mozilla/fxa-content-server/hooks","issue_events_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/fxa-content-server/events","assignees_url":"https://api.github.com/repos/mozilla/fxa-content-server/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/fxa-content-server/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/fxa-content-server/tags","blobs_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/fxa-content-server/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/fxa-content-server/languages","stargazers_url":"https://api.github.com/repos/mozilla/fxa-content-server/stargazers","contributors_url":"https://api.github.com/repos/mozilla/fxa-content-server/contributors","subscribers_url":"https://api.github.com/repos/mozilla/fxa-content-server/subscribers","subscription_url":"https://api.github.com/repos/mozilla/fxa-content-server/subscription","commits_url":"https://api.github.com/repos/mozilla/fxa-content-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/fxa-content-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/fxa-content-server/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/fxa-content-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/fxa-content-server/merges","archive_url":"https://api.github.com/repos/mozilla/fxa-content-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/fxa-content-server/downloads","issues_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/fxa-content-server/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/fxa-content-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/fxa-content-server/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/fxa-content-server/releases{/id}","created_at":"2013-07-30T23:35:35Z","updated_at":"2015-07-04T15:38:30Z","pushed_at":"2015-07-05T17:06:37Z","git_url":"git://github.com/mozilla/fxa-content-server.git","ssh_url":"git@github.com:mozilla/fxa-content-server.git","clone_url":"https://github.com/mozilla/fxa-content-server.git","svn_url":"https://github.com/mozilla/fxa-content-server","homepage":"","size":25852,"stargazers_count":69,"watchers_count":69,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":44,"mirror_url":null,"open_issues_count":225,"forks":44,"open_issues":225,"watchers":69,"default_branch":"master"}},"base":{"label":"mozilla:master","ref":"master","sha":"01dabb7f08ec33c33206e4cabad879c92864a6a9","user":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":11778024,"name":"fxa-content-server","full_name":"mozilla/fxa-content-server","owner":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/fxa-content-server","description":"Firefox Accounts Content Server","fork":false,"url":"https://api.github.com/repos/mozilla/fxa-content-server","forks_url":"https://api.github.com/repos/mozilla/fxa-content-server/forks","keys_url":"https://api.github.com/repos/mozilla/fxa-content-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/fxa-content-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/fxa-content-server/teams","hooks_url":"https://api.github.com/repos/mozilla/fxa-content-server/hooks","issue_events_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/fxa-content-server/events","assignees_url":"https://api.github.com/repos/mozilla/fxa-content-server/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/fxa-content-server/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/fxa-content-server/tags","blobs_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/fxa-content-server/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/fxa-content-server/languages","stargazers_url":"https://api.github.com/repos/mozilla/fxa-content-server/stargazers","contributors_url":"https://api.github.com/repos/mozilla/fxa-content-server/contributors","subscribers_url":"https://api.github.com/repos/mozilla/fxa-content-server/subscribers","subscription_url":"https://api.github.com/repos/mozilla/fxa-content-server/subscription","commits_url":"https://api.github.com/repos/mozilla/fxa-content-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/fxa-content-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/fxa-content-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/fxa-content-server/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/fxa-content-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/fxa-content-server/merges","archive_url":"https://api.github.com/repos/mozilla/fxa-content-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/fxa-content-server/downloads","issues_url":"https://api.github.com/repos/mozilla/fxa-content-server/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/fxa-content-server/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/fxa-content-server/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/fxa-content-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/fxa-content-server/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/fxa-content-server/releases{/id}","created_at":"2013-07-30T23:35:35Z","updated_at":"2015-07-04T15:38:30Z","pushed_at":"2015-07-05T17:06:37Z","git_url":"git://github.com/mozilla/fxa-content-server.git","ssh_url":"git@github.com:mozilla/fxa-content-server.git","clone_url":"https://github.com/mozilla/fxa-content-server.git","svn_url":"https://github.com/mozilla/fxa-content-server","homepage":"","size":25852,"stargazers_count":69,"watchers_count":69,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":44,"mirror_url":null,"open_issues_count":225,"forks":44,"open_issues":225,"watchers":69,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688"},"html":{"href":"https://github.com/mozilla/fxa-content-server/pull/2688"},"issue":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/issues/2688"},"comments":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/issues/2688/comments"},"review_comments":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688/comments"},"review_comment":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/pulls/2688/commits"},"statuses":{"href":"https://api.github.com/repos/mozilla/fxa-content-server/statuses/1f267956b752721b49f08cddfa4ce60355dba921"}}}}