{"action":"created","comment":{"url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/comments/195610901","pull_request_review_id":129016033,"id":195610901,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5NTYxMDkwMQ==","diff_hunk":"@@ -125,35 +125,42 @@ export default class CampaignUrl extends React.Component {\n    * state is activated. If there's an error shortening the URL, an alert\n    * is displayed.\n    */\n-  shortenUrl = async () => {\n-    this.setState({isShorteningUrl: true});\n+  shortenUrl = () => {\n+    this.setState({isShorteningUrl: true})\n \n-    try {\n-      let shortUrl = await shortenUrl(this.props.url);\n+    shortenUrl(this.props.url)\n+    .then(shortUrl => {\n       this.setState({\n         isShorteningUrl: false,\n         shortUrl: shortUrl,\n         showShortUrl: true,\n       });\n+      // TODO(nathanwest): Only send the event if the API was hit. Don't send\n+      // events for cache hits.\n       gaSendEvent({\n         category: 'Campaign URL',\n         action: 'shorten',\n-        label: '(not set)',\n-      });\n-    } catch (err) {\n+        label: 'success'\n+      })","path":"src/javascript/campaign-url-builder/components/campaign-url.js","position":27,"original_position":27,"commit_id":"ae151cd83241343fd5b0446d01c18664b9e0ff37","original_commit_id":"ae151cd83241343fd5b0446d01c18664b9e0ff37","user":{"login":"philipwalton","id":326742,"node_id":"MDQ6VXNlcjMyNjc0Mg==","avatar_url":"https://avatars1.githubusercontent.com/u/326742?v=4","gravatar_id":"","url":"https://api.github.com/users/philipwalton","html_url":"https://github.com/philipwalton","followers_url":"https://api.github.com/users/philipwalton/followers","following_url":"https://api.github.com/users/philipwalton/following{/other_user}","gists_url":"https://api.github.com/users/philipwalton/gists{/gist_id}","starred_url":"https://api.github.com/users/philipwalton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philipwalton/subscriptions","organizations_url":"https://api.github.com/users/philipwalton/orgs","repos_url":"https://api.github.com/users/philipwalton/repos","events_url":"https://api.github.com/users/philipwalton/events{/privacy}","received_events_url":"https://api.github.com/users/philipwalton/received_events","type":"User","site_admin":false},"body":"This should end in a semicolon.","created_at":"2018-06-15T00:51:01Z","updated_at":"2018-06-15T00:54:06Z","html_url":"https://github.com/googleanalytics/ga-dev-tools/pull/378#discussion_r195610901","pull_request_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/comments/195610901"},"html":{"href":"https://github.com/googleanalytics/ga-dev-tools/pull/378#discussion_r195610901"},"pull_request":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378"}}},"pull_request":{"url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378","id":195004599,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk1MDA0NTk5","html_url":"https://github.com/googleanalytics/ga-dev-tools/pull/378","diff_url":"https://github.com/googleanalytics/ga-dev-tools/pull/378.diff","patch_url":"https://github.com/googleanalytics/ga-dev-tools/pull/378.patch","issue_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues/378","number":378,"state":"open","locked":false,"title":"Add analytics to failed URL shorten requests","user":{"login":"Lucretiel","id":1823405,"node_id":"MDQ6VXNlcjE4MjM0MDU=","avatar_url":"https://avatars1.githubusercontent.com/u/1823405?v=4","gravatar_id":"","url":"https://api.github.com/users/Lucretiel","html_url":"https://github.com/Lucretiel","followers_url":"https://api.github.com/users/Lucretiel/followers","following_url":"https://api.github.com/users/Lucretiel/following{/other_user}","gists_url":"https://api.github.com/users/Lucretiel/gists{/gist_id}","starred_url":"https://api.github.com/users/Lucretiel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lucretiel/subscriptions","organizations_url":"https://api.github.com/users/Lucretiel/orgs","repos_url":"https://api.github.com/users/Lucretiel/repos","events_url":"https://api.github.com/users/Lucretiel/events{/privacy}","received_events_url":"https://api.github.com/users/Lucretiel/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-06-14T20:11:38Z","updated_at":"2018-06-15T00:54:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ad38d13e5df6de50ad4e6ec98dd8f32df09ffe1f","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":107918512,"node_id":"MDU6TGFiZWwxMDc5MTg1MTI=","url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"milestone":null,"commits_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378/commits","review_comments_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378/comments","review_comment_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/comments{/number}","comments_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues/378/comments","statuses_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/statuses/ae151cd83241343fd5b0446d01c18664b9e0ff37","head":{"label":"Lucretiel:failed-shorten-analytics","ref":"failed-shorten-analytics","sha":"ae151cd83241343fd5b0446d01c18664b9e0ff37","user":{"login":"Lucretiel","id":1823405,"node_id":"MDQ6VXNlcjE4MjM0MDU=","avatar_url":"https://avatars1.githubusercontent.com/u/1823405?v=4","gravatar_id":"","url":"https://api.github.com/users/Lucretiel","html_url":"https://github.com/Lucretiel","followers_url":"https://api.github.com/users/Lucretiel/followers","following_url":"https://api.github.com/users/Lucretiel/following{/other_user}","gists_url":"https://api.github.com/users/Lucretiel/gists{/gist_id}","starred_url":"https://api.github.com/users/Lucretiel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lucretiel/subscriptions","organizations_url":"https://api.github.com/users/Lucretiel/orgs","repos_url":"https://api.github.com/users/Lucretiel/repos","events_url":"https://api.github.com/users/Lucretiel/events{/privacy}","received_events_url":"https://api.github.com/users/Lucretiel/received_events","type":"User","site_admin":false},"repo":{"id":113231784,"node_id":"MDEwOlJlcG9zaXRvcnkxMTMyMzE3ODQ=","name":"ga-dev-tools","full_name":"Lucretiel/ga-dev-tools","owner":{"login":"Lucretiel","id":1823405,"node_id":"MDQ6VXNlcjE4MjM0MDU=","avatar_url":"https://avatars1.githubusercontent.com/u/1823405?v=4","gravatar_id":"","url":"https://api.github.com/users/Lucretiel","html_url":"https://github.com/Lucretiel","followers_url":"https://api.github.com/users/Lucretiel/followers","following_url":"https://api.github.com/users/Lucretiel/following{/other_user}","gists_url":"https://api.github.com/users/Lucretiel/gists{/gist_id}","starred_url":"https://api.github.com/users/Lucretiel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lucretiel/subscriptions","organizations_url":"https://api.github.com/users/Lucretiel/orgs","repos_url":"https://api.github.com/users/Lucretiel/repos","events_url":"https://api.github.com/users/Lucretiel/events{/privacy}","received_events_url":"https://api.github.com/users/Lucretiel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Lucretiel/ga-dev-tools","description":"A showcase of demos and tools built with the various Google Analytics APIs and Libraries.","fork":true,"url":"https://api.github.com/repos/Lucretiel/ga-dev-tools","forks_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/forks","keys_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/teams","hooks_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/hooks","issue_events_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/issues/events{/number}","events_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/events","assignees_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/assignees{/user}","branches_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/branches{/branch}","tags_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/tags","blobs_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/git/refs{/sha}","trees_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/statuses/{sha}","languages_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/languages","stargazers_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/stargazers","contributors_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/contributors","subscribers_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/subscribers","subscription_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/subscription","commits_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/commits{/sha}","git_commits_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/git/commits{/sha}","comments_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/comments{/number}","issue_comment_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/issues/comments{/number}","contents_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/contents/{+path}","compare_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/merges","archive_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/downloads","issues_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/issues{/number}","pulls_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/pulls{/number}","milestones_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/milestones{/number}","notifications_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/labels{/name}","releases_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/releases{/id}","deployments_url":"https://api.github.com/repos/Lucretiel/ga-dev-tools/deployments","created_at":"2017-12-05T20:52:55Z","updated_at":"2018-05-03T22:31:06Z","pushed_at":"2018-06-15T00:22:15Z","git_url":"git://github.com/Lucretiel/ga-dev-tools.git","ssh_url":"git@github.com:Lucretiel/ga-dev-tools.git","clone_url":"https://github.com/Lucretiel/ga-dev-tools.git","svn_url":"https://github.com/Lucretiel/ga-dev-tools","homepage":"https://ga-dev-tools.appspot.com/","size":3115,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"googleanalytics:master","ref":"master","sha":"94930ea38d80c2f63ebb653386167c8fca78130c","user":{"login":"googleanalytics","id":4327788,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQzMjc3ODg=","avatar_url":"https://avatars3.githubusercontent.com/u/4327788?v=4","gravatar_id":"","url":"https://api.github.com/users/googleanalytics","html_url":"https://github.com/googleanalytics","followers_url":"https://api.github.com/users/googleanalytics/followers","following_url":"https://api.github.com/users/googleanalytics/following{/other_user}","gists_url":"https://api.github.com/users/googleanalytics/gists{/gist_id}","starred_url":"https://api.github.com/users/googleanalytics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/googleanalytics/subscriptions","organizations_url":"https://api.github.com/users/googleanalytics/orgs","repos_url":"https://api.github.com/users/googleanalytics/repos","events_url":"https://api.github.com/users/googleanalytics/events{/privacy}","received_events_url":"https://api.github.com/users/googleanalytics/received_events","type":"Organization","site_admin":false},"repo":{"id":20975247,"node_id":"MDEwOlJlcG9zaXRvcnkyMDk3NTI0Nw==","name":"ga-dev-tools","full_name":"googleanalytics/ga-dev-tools","owner":{"login":"googleanalytics","id":4327788,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQzMjc3ODg=","avatar_url":"https://avatars3.githubusercontent.com/u/4327788?v=4","gravatar_id":"","url":"https://api.github.com/users/googleanalytics","html_url":"https://github.com/googleanalytics","followers_url":"https://api.github.com/users/googleanalytics/followers","following_url":"https://api.github.com/users/googleanalytics/following{/other_user}","gists_url":"https://api.github.com/users/googleanalytics/gists{/gist_id}","starred_url":"https://api.github.com/users/googleanalytics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/googleanalytics/subscriptions","organizations_url":"https://api.github.com/users/googleanalytics/orgs","repos_url":"https://api.github.com/users/googleanalytics/repos","events_url":"https://api.github.com/users/googleanalytics/events{/privacy}","received_events_url":"https://api.github.com/users/googleanalytics/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/googleanalytics/ga-dev-tools","description":"A showcase of demos and tools built with the various Google Analytics APIs and Libraries.","fork":false,"url":"https://api.github.com/repos/googleanalytics/ga-dev-tools","forks_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/forks","keys_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/keys{/key_id}","collaborators_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/teams","hooks_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/hooks","issue_events_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues/events{/number}","events_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/events","assignees_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/assignees{/user}","branches_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/branches{/branch}","tags_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/tags","blobs_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/git/refs{/sha}","trees_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/git/trees{/sha}","statuses_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/statuses/{sha}","languages_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/languages","stargazers_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/stargazers","contributors_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/contributors","subscribers_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/subscribers","subscription_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/subscription","commits_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/commits{/sha}","git_commits_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/git/commits{/sha}","comments_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/comments{/number}","issue_comment_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues/comments{/number}","contents_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/contents/{+path}","compare_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/compare/{base}...{head}","merges_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/merges","archive_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/downloads","issues_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues{/number}","pulls_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls{/number}","milestones_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/milestones{/number}","notifications_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/labels{/name}","releases_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/releases{/id}","deployments_url":"https://api.github.com/repos/googleanalytics/ga-dev-tools/deployments","created_at":"2014-06-18T19:31:01Z","updated_at":"2018-06-14T21:27:16Z","pushed_at":"2018-06-14T20:11:38Z","git_url":"git://github.com/googleanalytics/ga-dev-tools.git","ssh_url":"git@github.com:googleanalytics/ga-dev-tools.git","clone_url":"https://github.com/googleanalytics/ga-dev-tools.git","svn_url":"https://github.com/googleanalytics/ga-dev-tools","homepage":"https://ga-dev-tools.appspot.com/","size":3119,"stargazers_count":798,"watchers_count":798,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":394,"mirror_url":null,"archived":false,"open_issues_count":38,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":394,"open_issues":38,"watchers":798,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378"},"html":{"href":"https://github.com/googleanalytics/ga-dev-tools/pull/378"},"issue":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues/378"},"comments":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/issues/378/comments"},"review_comments":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378/comments"},"review_comment":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/pulls/378/commits"},"statuses":{"href":"https://api.github.com/repos/googleanalytics/ga-dev-tools/statuses/ae151cd83241343fd5b0446d01c18664b9e0ff37"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"philipwalton"}}