{"action":"created","comment":{"url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/comments/60636136","id":60636136,"diff_hunk":"@@ -16,7 +16,19 @@\n //3) Array.join() https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/join\n \n function performReplace(str, before, after) {\n-  //your code here\n+  var afterI = after;\n+  //reset after to include any uppercase elements of before\n+  if (before.charAt(0) === before.charAt(0).toUpperCase()) {\n+  \tafterI = after.replace(after.charAt(0), after.charAt(0).toUpperCase());\n+  }\n+  //reset after to include any lowercase elements of before\n+  if (before.charAt(0) === before.charAt(0).toLowerCase()) {\n+  \tafterI = after.replace(after.charAt(0), after.charAt(0).toLowerCase());\n+  }\n+  //replacements of befores with afters in string\n+  result = str.replace(before, afterI);\n+  console.log(result);","path":"replacement.js","position":30,"original_position":16,"commit_id":"f8bf4f74e58515c5eda367f16ed0cce8add1399a","original_commit_id":"f8bf4f74e58515c5eda367f16ed0cce8add1399a","user":{"login":"yabanci","id":1271345,"avatar_url":"https://avatars.githubusercontent.com/u/1271345?v=3","gravatar_id":"","url":"https://api.github.com/users/yabanci","html_url":"https://github.com/yabanci","followers_url":"https://api.github.com/users/yabanci/followers","following_url":"https://api.github.com/users/yabanci/following{/other_user}","gists_url":"https://api.github.com/users/yabanci/gists{/gist_id}","starred_url":"https://api.github.com/users/yabanci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yabanci/subscriptions","organizations_url":"https://api.github.com/users/yabanci/orgs","repos_url":"https://api.github.com/users/yabanci/repos","events_url":"https://api.github.com/users/yabanci/events{/privacy}","received_events_url":"https://api.github.com/users/yabanci/received_events","type":"User","site_admin":false},"body":"it is better to leave out the console.log once you are done debugging.","created_at":"2016-04-21T18:55:12Z","updated_at":"2016-04-21T18:55:12Z","html_url":"https://github.com/AnnieCannons/ac-algorithms/pull/9#discussion_r60636136","pull_request_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9","_links":{"self":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/comments/60636136"},"html":{"href":"https://github.com/AnnieCannons/ac-algorithms/pull/9#discussion_r60636136"},"pull_request":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9"}}},"pull_request":{"url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9","id":67049724,"html_url":"https://github.com/AnnieCannons/ac-algorithms/pull/9","diff_url":"https://github.com/AnnieCannons/ac-algorithms/pull/9.diff","patch_url":"https://github.com/AnnieCannons/ac-algorithms/pull/9.patch","issue_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues/9","number":9,"state":"open","locked":false,"title":"JLH Answer to replacements exercise","user":{"login":"jhubs","id":11729377,"avatar_url":"https://avatars.githubusercontent.com/u/11729377?v=3","gravatar_id":"","url":"https://api.github.com/users/jhubs","html_url":"https://github.com/jhubs","followers_url":"https://api.github.com/users/jhubs/followers","following_url":"https://api.github.com/users/jhubs/following{/other_user}","gists_url":"https://api.github.com/users/jhubs/gists{/gist_id}","starred_url":"https://api.github.com/users/jhubs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jhubs/subscriptions","organizations_url":"https://api.github.com/users/jhubs/orgs","repos_url":"https://api.github.com/users/jhubs/repos","events_url":"https://api.github.com/users/jhubs/events{/privacy}","received_events_url":"https://api.github.com/users/jhubs/received_events","type":"User","site_admin":false},"body":"for code review (not unless you have spare time)\r\n","created_at":"2016-04-19T16:31:41Z","updated_at":"2016-04-21T18:55:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"096b7e3aa644c53c3e8233b362c2b6ca699ecfa0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9/commits","review_comments_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9/comments","review_comment_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/comments{/number}","comments_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues/9/comments","statuses_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/statuses/f8bf4f74e58515c5eda367f16ed0cce8add1399a","head":{"label":"jhubs:jessica","ref":"jessica","sha":"f8bf4f74e58515c5eda367f16ed0cce8add1399a","user":{"login":"jhubs","id":11729377,"avatar_url":"https://avatars.githubusercontent.com/u/11729377?v=3","gravatar_id":"","url":"https://api.github.com/users/jhubs","html_url":"https://github.com/jhubs","followers_url":"https://api.github.com/users/jhubs/followers","following_url":"https://api.github.com/users/jhubs/following{/other_user}","gists_url":"https://api.github.com/users/jhubs/gists{/gist_id}","starred_url":"https://api.github.com/users/jhubs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jhubs/subscriptions","organizations_url":"https://api.github.com/users/jhubs/orgs","repos_url":"https://api.github.com/users/jhubs/repos","events_url":"https://api.github.com/users/jhubs/events{/privacy}","received_events_url":"https://api.github.com/users/jhubs/received_events","type":"User","site_admin":false},"repo":{"id":53759545,"name":"ac-algorithms","full_name":"jhubs/ac-algorithms","owner":{"login":"jhubs","id":11729377,"avatar_url":"https://avatars.githubusercontent.com/u/11729377?v=3","gravatar_id":"","url":"https://api.github.com/users/jhubs","html_url":"https://github.com/jhubs","followers_url":"https://api.github.com/users/jhubs/followers","following_url":"https://api.github.com/users/jhubs/following{/other_user}","gists_url":"https://api.github.com/users/jhubs/gists{/gist_id}","starred_url":"https://api.github.com/users/jhubs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jhubs/subscriptions","organizations_url":"https://api.github.com/users/jhubs/orgs","repos_url":"https://api.github.com/users/jhubs/repos","events_url":"https://api.github.com/users/jhubs/events{/privacy}","received_events_url":"https://api.github.com/users/jhubs/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jhubs/ac-algorithms","description":"","fork":true,"url":"https://api.github.com/repos/jhubs/ac-algorithms","forks_url":"https://api.github.com/repos/jhubs/ac-algorithms/forks","keys_url":"https://api.github.com/repos/jhubs/ac-algorithms/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jhubs/ac-algorithms/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jhubs/ac-algorithms/teams","hooks_url":"https://api.github.com/repos/jhubs/ac-algorithms/hooks","issue_events_url":"https://api.github.com/repos/jhubs/ac-algorithms/issues/events{/number}","events_url":"https://api.github.com/repos/jhubs/ac-algorithms/events","assignees_url":"https://api.github.com/repos/jhubs/ac-algorithms/assignees{/user}","branches_url":"https://api.github.com/repos/jhubs/ac-algorithms/branches{/branch}","tags_url":"https://api.github.com/repos/jhubs/ac-algorithms/tags","blobs_url":"https://api.github.com/repos/jhubs/ac-algorithms/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jhubs/ac-algorithms/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jhubs/ac-algorithms/git/refs{/sha}","trees_url":"https://api.github.com/repos/jhubs/ac-algorithms/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jhubs/ac-algorithms/statuses/{sha}","languages_url":"https://api.github.com/repos/jhubs/ac-algorithms/languages","stargazers_url":"https://api.github.com/repos/jhubs/ac-algorithms/stargazers","contributors_url":"https://api.github.com/repos/jhubs/ac-algorithms/contributors","subscribers_url":"https://api.github.com/repos/jhubs/ac-algorithms/subscribers","subscription_url":"https://api.github.com/repos/jhubs/ac-algorithms/subscription","commits_url":"https://api.github.com/repos/jhubs/ac-algorithms/commits{/sha}","git_commits_url":"https://api.github.com/repos/jhubs/ac-algorithms/git/commits{/sha}","comments_url":"https://api.github.com/repos/jhubs/ac-algorithms/comments{/number}","issue_comment_url":"https://api.github.com/repos/jhubs/ac-algorithms/issues/comments{/number}","contents_url":"https://api.github.com/repos/jhubs/ac-algorithms/contents/{+path}","compare_url":"https://api.github.com/repos/jhubs/ac-algorithms/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jhubs/ac-algorithms/merges","archive_url":"https://api.github.com/repos/jhubs/ac-algorithms/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jhubs/ac-algorithms/downloads","issues_url":"https://api.github.com/repos/jhubs/ac-algorithms/issues{/number}","pulls_url":"https://api.github.com/repos/jhubs/ac-algorithms/pulls{/number}","milestones_url":"https://api.github.com/repos/jhubs/ac-algorithms/milestones{/number}","notifications_url":"https://api.github.com/repos/jhubs/ac-algorithms/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jhubs/ac-algorithms/labels{/name}","releases_url":"https://api.github.com/repos/jhubs/ac-algorithms/releases{/id}","deployments_url":"https://api.github.com/repos/jhubs/ac-algorithms/deployments","created_at":"2016-03-13T00:06:06Z","updated_at":"2016-03-13T00:06:08Z","pushed_at":"2016-04-19T16:19:20Z","git_url":"git://github.com/jhubs/ac-algorithms.git","ssh_url":"git@github.com:jhubs/ac-algorithms.git","clone_url":"https://github.com/jhubs/ac-algorithms.git","svn_url":"https://github.com/jhubs/ac-algorithms","homepage":null,"size":38,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"AnnieCannons:jhubs","ref":"jhubs","sha":"5540ee850e2dd783e4a992a646447c9fa9d689b4","user":{"login":"AnnieCannons","id":11729384,"avatar_url":"https://avatars.githubusercontent.com/u/11729384?v=3","gravatar_id":"","url":"https://api.github.com/users/AnnieCannons","html_url":"https://github.com/AnnieCannons","followers_url":"https://api.github.com/users/AnnieCannons/followers","following_url":"https://api.github.com/users/AnnieCannons/following{/other_user}","gists_url":"https://api.github.com/users/AnnieCannons/gists{/gist_id}","starred_url":"https://api.github.com/users/AnnieCannons/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnnieCannons/subscriptions","organizations_url":"https://api.github.com/users/AnnieCannons/orgs","repos_url":"https://api.github.com/users/AnnieCannons/repos","events_url":"https://api.github.com/users/AnnieCannons/events{/privacy}","received_events_url":"https://api.github.com/users/AnnieCannons/received_events","type":"Organization","site_admin":false},"repo":{"id":54229662,"name":"ac-algorithms","full_name":"AnnieCannons/ac-algorithms","owner":{"login":"AnnieCannons","id":11729384,"avatar_url":"https://avatars.githubusercontent.com/u/11729384?v=3","gravatar_id":"","url":"https://api.github.com/users/AnnieCannons","html_url":"https://github.com/AnnieCannons","followers_url":"https://api.github.com/users/AnnieCannons/followers","following_url":"https://api.github.com/users/AnnieCannons/following{/other_user}","gists_url":"https://api.github.com/users/AnnieCannons/gists{/gist_id}","starred_url":"https://api.github.com/users/AnnieCannons/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnnieCannons/subscriptions","organizations_url":"https://api.github.com/users/AnnieCannons/orgs","repos_url":"https://api.github.com/users/AnnieCannons/repos","events_url":"https://api.github.com/users/AnnieCannons/events{/privacy}","received_events_url":"https://api.github.com/users/AnnieCannons/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/AnnieCannons/ac-algorithms","description":"","fork":true,"url":"https://api.github.com/repos/AnnieCannons/ac-algorithms","forks_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/forks","keys_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/keys{/key_id}","collaborators_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/teams","hooks_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/hooks","issue_events_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues/events{/number}","events_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/events","assignees_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/assignees{/user}","branches_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/branches{/branch}","tags_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/tags","blobs_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/git/refs{/sha}","trees_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/git/trees{/sha}","statuses_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/statuses/{sha}","languages_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/languages","stargazers_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/stargazers","contributors_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/contributors","subscribers_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/subscribers","subscription_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/subscription","commits_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/commits{/sha}","git_commits_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/git/commits{/sha}","comments_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/comments{/number}","issue_comment_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues/comments{/number}","contents_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/contents/{+path}","compare_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/compare/{base}...{head}","merges_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/merges","archive_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/downloads","issues_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues{/number}","pulls_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls{/number}","milestones_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/milestones{/number}","notifications_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/labels{/name}","releases_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/releases{/id}","deployments_url":"https://api.github.com/repos/AnnieCannons/ac-algorithms/deployments","created_at":"2016-03-18T20:31:49Z","updated_at":"2016-03-18T20:31:50Z","pushed_at":"2016-04-19T16:31:41Z","git_url":"git://github.com/AnnieCannons/ac-algorithms.git","ssh_url":"git@github.com:AnnieCannons/ac-algorithms.git","clone_url":"https://github.com/AnnieCannons/ac-algorithms.git","svn_url":"https://github.com/AnnieCannons/ac-algorithms","homepage":null,"size":26,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9"},"html":{"href":"https://github.com/AnnieCannons/ac-algorithms/pull/9"},"issue":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues/9"},"comments":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/issues/9/comments"},"review_comments":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9/comments"},"review_comment":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/pulls/9/commits"},"statuses":{"href":"https://api.github.com/repos/AnnieCannons/ac-algorithms/statuses/f8bf4f74e58515c5eda367f16ed0cce8add1399a"}}}}