{"action":"created","comment":{"url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments/150869571","pull_request_review_id":76483956,"id":150869571,"diff_hunk":"@@ -40,7 +40,15 @@ const TabbedNavigationContainer = (props) => {\n   const additionalPages = pages\n     .filter(page => ! page.fields.hideFromNavigation)\n     .map((page) => {\n-      const path = join('/us/campaigns', campaignSlug, campaignPaths.pages, page.fields.slug);\n+      const pageHasCampaignSlug = page.fields.slug.indexOf(campaignSlug) >= 0;\n+      let pageSlug = page.fields.slug;\n+      let path = '/us/campaigns';\n+\n+      if (pageHasCampaignSlug) {\n+        pageSlug = pageSlug.replace(`${campaignSlug}/`, '');\n+      }\n+\n+      path += `/${campaignSlug}${campaignPaths.pages}${pageSlug}`;","path":"resources/assets/components/Navigation/TabbedNavigationContainer.js","position":13,"original_position":13,"commit_id":"f613c288bc17b6def88a391b0477a47ba68d74c3","original_commit_id":"f613c288bc17b6def88a391b0477a47ba68d74c3","user":{"login":"weerd","id":105849,"avatar_url":"https://avatars1.githubusercontent.com/u/105849?v=4","gravatar_id":"","url":"https://api.github.com/users/weerd","html_url":"https://github.com/weerd","followers_url":"https://api.github.com/users/weerd/followers","following_url":"https://api.github.com/users/weerd/following{/other_user}","gists_url":"https://api.github.com/users/weerd/gists{/gist_id}","starred_url":"https://api.github.com/users/weerd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weerd/subscriptions","organizations_url":"https://api.github.com/users/weerd/orgs","repos_url":"https://api.github.com/users/weerd/repos","events_url":"https://api.github.com/users/weerd/events{/privacy}","received_events_url":"https://api.github.com/users/weerd/received_events","type":"User","site_admin":false},"body":"Looks much better!\r\n\r\nOne thing, can you switch to build the path using `join` like we do [here](https://github.com/DoSomething/phoenix-next/blob/dev/resources/assets/components/Navigation/TabbedNavigationContainer.js#L43) @DFurnes has pointed out in the past that the `path.join()` method does a really good job of making sure it forms a proper url in case anything is missing from the string like `/` or whatever :)","created_at":"2017-11-14T15:38:45Z","updated_at":"2017-11-14T15:38:45Z","html_url":"https://github.com/DoSomething/phoenix-next/pull/507#discussion_r150869571","pull_request_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments/150869571"},"html":{"href":"https://github.com/DoSomething/phoenix-next/pull/507#discussion_r150869571"},"pull_request":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507"}}},"pull_request":{"url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507","id":152362124,"html_url":"https://github.com/DoSomething/phoenix-next/pull/507","diff_url":"https://github.com/DoSomething/phoenix-next/pull/507.diff","patch_url":"https://github.com/DoSomething/phoenix-next/pull/507.patch","issue_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/507","number":507,"state":"open","locked":false,"title":"fixing slugs","user":{"login":"itsjoekent","id":897368,"avatar_url":"https://avatars0.githubusercontent.com/u/897368?v=4","gravatar_id":"","url":"https://api.github.com/users/itsjoekent","html_url":"https://github.com/itsjoekent","followers_url":"https://api.github.com/users/itsjoekent/followers","following_url":"https://api.github.com/users/itsjoekent/following{/other_user}","gists_url":"https://api.github.com/users/itsjoekent/gists{/gist_id}","starred_url":"https://api.github.com/users/itsjoekent/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/itsjoekent/subscriptions","organizations_url":"https://api.github.com/users/itsjoekent/orgs","repos_url":"https://api.github.com/users/itsjoekent/repos","events_url":"https://api.github.com/users/itsjoekent/events{/privacy}","received_events_url":"https://api.github.com/users/itsjoekent/received_events","type":"User","site_admin":false},"body":"i will fill this out when i get a sec, probably \r\n","created_at":"2017-11-13T22:14:41Z","updated_at":"2017-11-14T15:38:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f20bd64ff040cfa1c70586c57ddd25a5e94fa8bd","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507/commits","review_comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507/comments","review_comment_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments{/number}","comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/507/comments","statuses_url":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/f613c288bc17b6def88a391b0477a47ba68d74c3","head":{"label":"DoSomething:slug","ref":"slug","sha":"f613c288bc17b6def88a391b0477a47ba68d74c3","user":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"repo":{"id":75642790,"name":"phoenix-next","full_name":"DoSomething/phoenix-next","owner":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/DoSomething/phoenix-next","description":"🔥 The new DoSomething.org campaign template.","fork":false,"url":"https://api.github.com/repos/DoSomething/phoenix-next","forks_url":"https://api.github.com/repos/DoSomething/phoenix-next/forks","keys_url":"https://api.github.com/repos/DoSomething/phoenix-next/keys{/key_id}","collaborators_url":"https://api.github.com/repos/DoSomething/phoenix-next/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/DoSomething/phoenix-next/teams","hooks_url":"https://api.github.com/repos/DoSomething/phoenix-next/hooks","issue_events_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/events{/number}","events_url":"https://api.github.com/repos/DoSomething/phoenix-next/events","assignees_url":"https://api.github.com/repos/DoSomething/phoenix-next/assignees{/user}","branches_url":"https://api.github.com/repos/DoSomething/phoenix-next/branches{/branch}","tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/tags","blobs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/refs{/sha}","trees_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/trees{/sha}","statuses_url":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/{sha}","languages_url":"https://api.github.com/repos/DoSomething/phoenix-next/languages","stargazers_url":"https://api.github.com/repos/DoSomething/phoenix-next/stargazers","contributors_url":"https://api.github.com/repos/DoSomething/phoenix-next/contributors","subscribers_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscribers","subscription_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscription","commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/commits{/sha}","git_commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/commits{/sha}","comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/comments{/number}","issue_comment_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/comments{/number}","contents_url":"https://api.github.com/repos/DoSomething/phoenix-next/contents/{+path}","compare_url":"https://api.github.com/repos/DoSomething/phoenix-next/compare/{base}...{head}","merges_url":"https://api.github.com/repos/DoSomething/phoenix-next/merges","archive_url":"https://api.github.com/repos/DoSomething/phoenix-next/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/DoSomething/phoenix-next/downloads","issues_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues{/number}","pulls_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls{/number}","milestones_url":"https://api.github.com/repos/DoSomething/phoenix-next/milestones{/number}","notifications_url":"https://api.github.com/repos/DoSomething/phoenix-next/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/DoSomething/phoenix-next/labels{/name}","releases_url":"https://api.github.com/repos/DoSomething/phoenix-next/releases{/id}","deployments_url":"https://api.github.com/repos/DoSomething/phoenix-next/deployments","created_at":"2016-12-05T16:08:36Z","updated_at":"2017-10-24T20:40:53Z","pushed_at":"2017-11-14T15:25:33Z","git_url":"git://github.com/DoSomething/phoenix-next.git","ssh_url":"git@github.com:DoSomething/phoenix-next.git","clone_url":"https://github.com/DoSomething/phoenix-next.git","svn_url":"https://github.com/DoSomething/phoenix-next","homepage":"https://next.dosomething.org","size":2923,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":16,"forks":7,"open_issues":16,"watchers":0,"default_branch":"dev"}},"base":{"label":"DoSomething:dev","ref":"dev","sha":"de31c8fd80bc991cdb0b5a1a56b301e3c4d2e6bc","user":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"repo":{"id":75642790,"name":"phoenix-next","full_name":"DoSomething/phoenix-next","owner":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/DoSomething/phoenix-next","description":"🔥 The new DoSomething.org campaign template.","fork":false,"url":"https://api.github.com/repos/DoSomething/phoenix-next","forks_url":"https://api.github.com/repos/DoSomething/phoenix-next/forks","keys_url":"https://api.github.com/repos/DoSomething/phoenix-next/keys{/key_id}","collaborators_url":"https://api.github.com/repos/DoSomething/phoenix-next/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/DoSomething/phoenix-next/teams","hooks_url":"https://api.github.com/repos/DoSomething/phoenix-next/hooks","issue_events_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/events{/number}","events_url":"https://api.github.com/repos/DoSomething/phoenix-next/events","assignees_url":"https://api.github.com/repos/DoSomething/phoenix-next/assignees{/user}","branches_url":"https://api.github.com/repos/DoSomething/phoenix-next/branches{/branch}","tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/tags","blobs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/refs{/sha}","trees_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/trees{/sha}","statuses_url":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/{sha}","languages_url":"https://api.github.com/repos/DoSomething/phoenix-next/languages","stargazers_url":"https://api.github.com/repos/DoSomething/phoenix-next/stargazers","contributors_url":"https://api.github.com/repos/DoSomething/phoenix-next/contributors","subscribers_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscribers","subscription_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscription","commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/commits{/sha}","git_commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/commits{/sha}","comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/comments{/number}","issue_comment_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/comments{/number}","contents_url":"https://api.github.com/repos/DoSomething/phoenix-next/contents/{+path}","compare_url":"https://api.github.com/repos/DoSomething/phoenix-next/compare/{base}...{head}","merges_url":"https://api.github.com/repos/DoSomething/phoenix-next/merges","archive_url":"https://api.github.com/repos/DoSomething/phoenix-next/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/DoSomething/phoenix-next/downloads","issues_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues{/number}","pulls_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls{/number}","milestones_url":"https://api.github.com/repos/DoSomething/phoenix-next/milestones{/number}","notifications_url":"https://api.github.com/repos/DoSomething/phoenix-next/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/DoSomething/phoenix-next/labels{/name}","releases_url":"https://api.github.com/repos/DoSomething/phoenix-next/releases{/id}","deployments_url":"https://api.github.com/repos/DoSomething/phoenix-next/deployments","created_at":"2016-12-05T16:08:36Z","updated_at":"2017-10-24T20:40:53Z","pushed_at":"2017-11-14T15:25:33Z","git_url":"git://github.com/DoSomething/phoenix-next.git","ssh_url":"git@github.com:DoSomething/phoenix-next.git","clone_url":"https://github.com/DoSomething/phoenix-next.git","svn_url":"https://github.com/DoSomething/phoenix-next","homepage":"https://next.dosomething.org","size":2923,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":16,"forks":7,"open_issues":16,"watchers":0,"default_branch":"dev"}},"_links":{"self":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507"},"html":{"href":"https://github.com/DoSomething/phoenix-next/pull/507"},"issue":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/issues/507"},"comments":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/issues/507/comments"},"review_comments":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507/comments"},"review_comment":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/507/commits"},"statuses":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/f613c288bc17b6def88a391b0477a47ba68d74c3"}},"author_association":"OWNER"}}
{"actor":{"display_login":"weerd"}}