{"action":"created","comment":{"url":"https://api.github.com/repos/patrickshobe/complete_me/pulls/comments/202215391","pull_request_review_id":136872725,"id":202215391,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwMjIxNTM5MQ==","diff_hunk":"@@ -127,22 +142,22 @@ def delete_word(word)\n     iteration_counter = 0\n     delete_from_hash(word)\n     until word_string.empty?\n+      # This could probably be broken up into if / elsif clauses\n+      # Generally it is considered a code smell to have nested if statements\n+      # This could be made even beter by breaking this chunk into it's own method.\n+      # Then you get a nice english sounding thing that is basically\n+      # until word string empty\n+      # do_something\n+      # Sandi Metz has a rule that methods shouldn't exceed 3-5 lines. There\n+      # are always exceptions, but the leaner your methods are the easier\n+      # your code will be the read and maintain\n       previous_node = find_node(word_string)\n       current_node = find_node(word_string.chop!)\n       iteration_counter += 1\n-\n-      if iteration_counter == 1\n-        if previous_node.children.length < 1\n+      if iteration_counter == 1 && previous_node.children.length < 1\n           current_node.children.delete(previous_node)\n-        else\n-          break\n-        end\n-      else\n-        if previous_node.children.length < 1 && previous_node.is_word == false\n+      elsif previous_node.children.length < 1 && previous_node.is_word == false","path":"lib/complete_me.rb","position":76,"original_position":76,"commit_id":"6937b7b36a5ea02d446f34186773e189edaf6ec0","original_commit_id":"6937b7b36a5ea02d446f34186773e189edaf6ec0","user":{"login":"houndci-bot","id":6697940,"node_id":"MDQ6VXNlcjY2OTc5NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Style/ZeroLengthPredicate: Use empty? instead of length < 1.","created_at":"2018-07-13T00:20:50Z","updated_at":"2018-07-13T00:20:51Z","html_url":"https://github.com/patrickshobe/complete_me/pull/19#discussion_r202215391","pull_request_url":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/patrickshobe/complete_me/pulls/comments/202215391"},"html":{"href":"https://github.com/patrickshobe/complete_me/pull/19#discussion_r202215391"},"pull_request":{"href":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19"}}},"pull_request":{"url":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19","id":201158474,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAxMTU4NDc0","html_url":"https://github.com/patrickshobe/complete_me/pull/19","diff_url":"https://github.com/patrickshobe/complete_me/pull/19.diff","patch_url":"https://github.com/patrickshobe/complete_me/pull/19.patch","issue_url":"https://api.github.com/repos/patrickshobe/complete_me/issues/19","number":19,"state":"open","locked":false,"title":"add my comments","user":{"login":"boveus","id":20469703,"node_id":"MDQ6VXNlcjIwNDY5NzAz","avatar_url":"https://avatars2.githubusercontent.com/u/20469703?v=4","gravatar_id":"","url":"https://api.github.com/users/boveus","html_url":"https://github.com/boveus","followers_url":"https://api.github.com/users/boveus/followers","following_url":"https://api.github.com/users/boveus/following{/other_user}","gists_url":"https://api.github.com/users/boveus/gists{/gist_id}","starred_url":"https://api.github.com/users/boveus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boveus/subscriptions","organizations_url":"https://api.github.com/users/boveus/orgs","repos_url":"https://api.github.com/users/boveus/repos","events_url":"https://api.github.com/users/boveus/events{/privacy}","received_events_url":"https://api.github.com/users/boveus/received_events","type":"User","site_admin":false},"body":"hey @patrickshobe this is good.  I added some comments about things I think might be helpful to dig into a little and some stylistic things.  I didn't really dig into the algorithmic complexity or performance of the code, though.\r\n\r\nOverall it seems like it was well organized and clear what was going on in the code.  There were only a few areas I thought it needed to get touched up and a couple of improvements that definitely would not have been obvious to me during mod 1.\r\n\r\nGood job","created_at":"2018-07-13T00:20:39Z","updated_at":"2018-07-13T00:20:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d091cb1aee3357e38a7695d882022e9fdd69eff7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19/commits","review_comments_url":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19/comments","review_comment_url":"https://api.github.com/repos/patrickshobe/complete_me/pulls/comments{/number}","comments_url":"https://api.github.com/repos/patrickshobe/complete_me/issues/19/comments","statuses_url":"https://api.github.com/repos/patrickshobe/complete_me/statuses/6937b7b36a5ea02d446f34186773e189edaf6ec0","head":{"label":"boveus:master","ref":"master","sha":"6937b7b36a5ea02d446f34186773e189edaf6ec0","user":{"login":"boveus","id":20469703,"node_id":"MDQ6VXNlcjIwNDY5NzAz","avatar_url":"https://avatars2.githubusercontent.com/u/20469703?v=4","gravatar_id":"","url":"https://api.github.com/users/boveus","html_url":"https://github.com/boveus","followers_url":"https://api.github.com/users/boveus/followers","following_url":"https://api.github.com/users/boveus/following{/other_user}","gists_url":"https://api.github.com/users/boveus/gists{/gist_id}","starred_url":"https://api.github.com/users/boveus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boveus/subscriptions","organizations_url":"https://api.github.com/users/boveus/orgs","repos_url":"https://api.github.com/users/boveus/repos","events_url":"https://api.github.com/users/boveus/events{/privacy}","received_events_url":"https://api.github.com/users/boveus/received_events","type":"User","site_admin":false},"repo":{"id":140760714,"node_id":"MDEwOlJlcG9zaXRvcnkxNDA3NjA3MTQ=","name":"complete_me-1","full_name":"boveus/complete_me-1","owner":{"login":"boveus","id":20469703,"node_id":"MDQ6VXNlcjIwNDY5NzAz","avatar_url":"https://avatars2.githubusercontent.com/u/20469703?v=4","gravatar_id":"","url":"https://api.github.com/users/boveus","html_url":"https://github.com/boveus","followers_url":"https://api.github.com/users/boveus/followers","following_url":"https://api.github.com/users/boveus/following{/other_user}","gists_url":"https://api.github.com/users/boveus/gists{/gist_id}","starred_url":"https://api.github.com/users/boveus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/boveus/subscriptions","organizations_url":"https://api.github.com/users/boveus/orgs","repos_url":"https://api.github.com/users/boveus/repos","events_url":"https://api.github.com/users/boveus/events{/privacy}","received_events_url":"https://api.github.com/users/boveus/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/boveus/complete_me-1","description":null,"fork":true,"url":"https://api.github.com/repos/boveus/complete_me-1","forks_url":"https://api.github.com/repos/boveus/complete_me-1/forks","keys_url":"https://api.github.com/repos/boveus/complete_me-1/keys{/key_id}","collaborators_url":"https://api.github.com/repos/boveus/complete_me-1/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/boveus/complete_me-1/teams","hooks_url":"https://api.github.com/repos/boveus/complete_me-1/hooks","issue_events_url":"https://api.github.com/repos/boveus/complete_me-1/issues/events{/number}","events_url":"https://api.github.com/repos/boveus/complete_me-1/events","assignees_url":"https://api.github.com/repos/boveus/complete_me-1/assignees{/user}","branches_url":"https://api.github.com/repos/boveus/complete_me-1/branches{/branch}","tags_url":"https://api.github.com/repos/boveus/complete_me-1/tags","blobs_url":"https://api.github.com/repos/boveus/complete_me-1/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/boveus/complete_me-1/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/boveus/complete_me-1/git/refs{/sha}","trees_url":"https://api.github.com/repos/boveus/complete_me-1/git/trees{/sha}","statuses_url":"https://api.github.com/repos/boveus/complete_me-1/statuses/{sha}","languages_url":"https://api.github.com/repos/boveus/complete_me-1/languages","stargazers_url":"https://api.github.com/repos/boveus/complete_me-1/stargazers","contributors_url":"https://api.github.com/repos/boveus/complete_me-1/contributors","subscribers_url":"https://api.github.com/repos/boveus/complete_me-1/subscribers","subscription_url":"https://api.github.com/repos/boveus/complete_me-1/subscription","commits_url":"https://api.github.com/repos/boveus/complete_me-1/commits{/sha}","git_commits_url":"https://api.github.com/repos/boveus/complete_me-1/git/commits{/sha}","comments_url":"https://api.github.com/repos/boveus/complete_me-1/comments{/number}","issue_comment_url":"https://api.github.com/repos/boveus/complete_me-1/issues/comments{/number}","contents_url":"https://api.github.com/repos/boveus/complete_me-1/contents/{+path}","compare_url":"https://api.github.com/repos/boveus/complete_me-1/compare/{base}...{head}","merges_url":"https://api.github.com/repos/boveus/complete_me-1/merges","archive_url":"https://api.github.com/repos/boveus/complete_me-1/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/boveus/complete_me-1/downloads","issues_url":"https://api.github.com/repos/boveus/complete_me-1/issues{/number}","pulls_url":"https://api.github.com/repos/boveus/complete_me-1/pulls{/number}","milestones_url":"https://api.github.com/repos/boveus/complete_me-1/milestones{/number}","notifications_url":"https://api.github.com/repos/boveus/complete_me-1/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/boveus/complete_me-1/labels{/name}","releases_url":"https://api.github.com/repos/boveus/complete_me-1/releases{/id}","deployments_url":"https://api.github.com/repos/boveus/complete_me-1/deployments","created_at":"2018-07-12T20:17:37Z","updated_at":"2018-07-13T00:17:42Z","pushed_at":"2018-07-13T00:17:41Z","git_url":"git://github.com/boveus/complete_me-1.git","ssh_url":"git@github.com:boveus/complete_me-1.git","clone_url":"https://github.com/boveus/complete_me-1.git","svn_url":"https://github.com/boveus/complete_me-1","homepage":null,"size":9473,"stargazers_count":0,"watchers_count":0,"language":"Ruby","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":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"patrickshobe:master","ref":"master","sha":"e00aeda463537bdbd8a7121d83afa1f404c993c6","user":{"login":"patrickshobe","id":32880860,"node_id":"MDQ6VXNlcjMyODgwODYw","avatar_url":"https://avatars3.githubusercontent.com/u/32880860?v=4","gravatar_id":"","url":"https://api.github.com/users/patrickshobe","html_url":"https://github.com/patrickshobe","followers_url":"https://api.github.com/users/patrickshobe/followers","following_url":"https://api.github.com/users/patrickshobe/following{/other_user}","gists_url":"https://api.github.com/users/patrickshobe/gists{/gist_id}","starred_url":"https://api.github.com/users/patrickshobe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patrickshobe/subscriptions","organizations_url":"https://api.github.com/users/patrickshobe/orgs","repos_url":"https://api.github.com/users/patrickshobe/repos","events_url":"https://api.github.com/users/patrickshobe/events{/privacy}","received_events_url":"https://api.github.com/users/patrickshobe/received_events","type":"User","site_admin":false},"repo":{"id":140187536,"node_id":"MDEwOlJlcG9zaXRvcnkxNDAxODc1MzY=","name":"complete_me","full_name":"patrickshobe/complete_me","owner":{"login":"patrickshobe","id":32880860,"node_id":"MDQ6VXNlcjMyODgwODYw","avatar_url":"https://avatars3.githubusercontent.com/u/32880860?v=4","gravatar_id":"","url":"https://api.github.com/users/patrickshobe","html_url":"https://github.com/patrickshobe","followers_url":"https://api.github.com/users/patrickshobe/followers","following_url":"https://api.github.com/users/patrickshobe/following{/other_user}","gists_url":"https://api.github.com/users/patrickshobe/gists{/gist_id}","starred_url":"https://api.github.com/users/patrickshobe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patrickshobe/subscriptions","organizations_url":"https://api.github.com/users/patrickshobe/orgs","repos_url":"https://api.github.com/users/patrickshobe/repos","events_url":"https://api.github.com/users/patrickshobe/events{/privacy}","received_events_url":"https://api.github.com/users/patrickshobe/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/patrickshobe/complete_me","description":null,"fork":false,"url":"https://api.github.com/repos/patrickshobe/complete_me","forks_url":"https://api.github.com/repos/patrickshobe/complete_me/forks","keys_url":"https://api.github.com/repos/patrickshobe/complete_me/keys{/key_id}","collaborators_url":"https://api.github.com/repos/patrickshobe/complete_me/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/patrickshobe/complete_me/teams","hooks_url":"https://api.github.com/repos/patrickshobe/complete_me/hooks","issue_events_url":"https://api.github.com/repos/patrickshobe/complete_me/issues/events{/number}","events_url":"https://api.github.com/repos/patrickshobe/complete_me/events","assignees_url":"https://api.github.com/repos/patrickshobe/complete_me/assignees{/user}","branches_url":"https://api.github.com/repos/patrickshobe/complete_me/branches{/branch}","tags_url":"https://api.github.com/repos/patrickshobe/complete_me/tags","blobs_url":"https://api.github.com/repos/patrickshobe/complete_me/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/patrickshobe/complete_me/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/patrickshobe/complete_me/git/refs{/sha}","trees_url":"https://api.github.com/repos/patrickshobe/complete_me/git/trees{/sha}","statuses_url":"https://api.github.com/repos/patrickshobe/complete_me/statuses/{sha}","languages_url":"https://api.github.com/repos/patrickshobe/complete_me/languages","stargazers_url":"https://api.github.com/repos/patrickshobe/complete_me/stargazers","contributors_url":"https://api.github.com/repos/patrickshobe/complete_me/contributors","subscribers_url":"https://api.github.com/repos/patrickshobe/complete_me/subscribers","subscription_url":"https://api.github.com/repos/patrickshobe/complete_me/subscription","commits_url":"https://api.github.com/repos/patrickshobe/complete_me/commits{/sha}","git_commits_url":"https://api.github.com/repos/patrickshobe/complete_me/git/commits{/sha}","comments_url":"https://api.github.com/repos/patrickshobe/complete_me/comments{/number}","issue_comment_url":"https://api.github.com/repos/patrickshobe/complete_me/issues/comments{/number}","contents_url":"https://api.github.com/repos/patrickshobe/complete_me/contents/{+path}","compare_url":"https://api.github.com/repos/patrickshobe/complete_me/compare/{base}...{head}","merges_url":"https://api.github.com/repos/patrickshobe/complete_me/merges","archive_url":"https://api.github.com/repos/patrickshobe/complete_me/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/patrickshobe/complete_me/downloads","issues_url":"https://api.github.com/repos/patrickshobe/complete_me/issues{/number}","pulls_url":"https://api.github.com/repos/patrickshobe/complete_me/pulls{/number}","milestones_url":"https://api.github.com/repos/patrickshobe/complete_me/milestones{/number}","notifications_url":"https://api.github.com/repos/patrickshobe/complete_me/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/patrickshobe/complete_me/labels{/name}","releases_url":"https://api.github.com/repos/patrickshobe/complete_me/releases{/id}","deployments_url":"https://api.github.com/repos/patrickshobe/complete_me/deployments","created_at":"2018-07-08T17:15:05Z","updated_at":"2018-07-12T03:15:42Z","pushed_at":"2018-07-13T00:20:40Z","git_url":"git://github.com/patrickshobe/complete_me.git","ssh_url":"git@github.com:patrickshobe/complete_me.git","clone_url":"https://github.com/patrickshobe/complete_me.git","svn_url":"https://github.com/patrickshobe/complete_me","homepage":null,"size":9473,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19"},"html":{"href":"https://github.com/patrickshobe/complete_me/pull/19"},"issue":{"href":"https://api.github.com/repos/patrickshobe/complete_me/issues/19"},"comments":{"href":"https://api.github.com/repos/patrickshobe/complete_me/issues/19/comments"},"review_comments":{"href":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19/comments"},"review_comment":{"href":"https://api.github.com/repos/patrickshobe/complete_me/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/patrickshobe/complete_me/pulls/19/commits"},"statuses":{"href":"https://api.github.com/repos/patrickshobe/complete_me/statuses/6937b7b36a5ea02d446f34186773e189edaf6ec0"}},"author_association":"NONE"}}
{"actor":{"display_login":"houndci-bot"}}