{"action":"created","comment":{"url":"https://api.github.com/repos/thecartercenter/elmo/pulls/comments/26767476","id":26767476,"diff_hunk":"@@ -19,14 +19,13 @@ class FormItem < ActiveRecord::Base\n \n   # Gets all leaves of the subtree headed by this FormItem, sorted.\n   # These should all be Questionings.\n-  def sorted_leaves(eager_load = nil)\n-    _sorted_leaves(arrange_and_sort(eager_load).values[0])\n+  def sorted_leaves\n+    _sorted_leaves(arrange_and_sort().values[0])\n   end\n \n-  def arrange_and_sort(eager_load = nil)\n+  def arrange_and_sort\n     # This is the only way (apparently) to do eager loading with arrange.\n-    self.class.arrange_nodes(subtree.all(include: eager_load,\n-      order: '(case when ancestry is null then 0 else 1 end), ancestry, rank'))\n+    self.class.arrange_nodes(subtree.order('(case when ancestry is null then 0 else 1 end), ancestry, rank').to_a)","path":"app/models/form_item.rb","position":15,"original_position":15,"commit_id":"b25d3c766827cd5efab73547359c0ebe8d29922c","original_commit_id":"32d1b9ce58149386b90dd2f2a9f80f801453be18","user":{"login":"mkuklis","id":63545,"avatar_url":"https://avatars.githubusercontent.com/u/63545?v=3","gravatar_id":"","url":"https://api.github.com/users/mkuklis","html_url":"https://github.com/mkuklis","followers_url":"https://api.github.com/users/mkuklis/followers","following_url":"https://api.github.com/users/mkuklis/following{/other_user}","gists_url":"https://api.github.com/users/mkuklis/gists{/gist_id}","starred_url":"https://api.github.com/users/mkuklis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mkuklis/subscriptions","organizations_url":"https://api.github.com/users/mkuklis/orgs","repos_url":"https://api.github.com/users/mkuklis/repos","events_url":"https://api.github.com/users/mkuklis/events{/privacy}","received_events_url":"https://api.github.com/users/mkuklis/received_events","type":"User","site_admin":false},"body":"eager_load was never used.","created_at":"2015-03-19T15:53:28Z","updated_at":"2015-03-19T15:53:28Z","html_url":"https://github.com/thecartercenter/elmo/pull/51#discussion_r26767476","pull_request_url":"https://api.github.com/repos/thecartercenter/elmo/pulls/51","_links":{"self":{"href":"https://api.github.com/repos/thecartercenter/elmo/pulls/comments/26767476"},"html":{"href":"https://github.com/thecartercenter/elmo/pull/51#discussion_r26767476"},"pull_request":{"href":"https://api.github.com/repos/thecartercenter/elmo/pulls/51"}}},"pull_request":{"url":"https://api.github.com/repos/thecartercenter/elmo/pulls/51","id":31365416,"html_url":"https://github.com/thecartercenter/elmo/pull/51","diff_url":"https://github.com/thecartercenter/elmo/pull/51.diff","patch_url":"https://github.com/thecartercenter/elmo/pull/51.patch","issue_url":"https://api.github.com/repos/thecartercenter/elmo/issues/51","number":51,"state":"open","locked":false,"title":"2104 upgrade to rails 4","user":{"login":"hooverlunch","id":702320,"avatar_url":"https://avatars.githubusercontent.com/u/702320?v=3","gravatar_id":"","url":"https://api.github.com/users/hooverlunch","html_url":"https://github.com/hooverlunch","followers_url":"https://api.github.com/users/hooverlunch/followers","following_url":"https://api.github.com/users/hooverlunch/following{/other_user}","gists_url":"https://api.github.com/users/hooverlunch/gists{/gist_id}","starred_url":"https://api.github.com/users/hooverlunch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hooverlunch/subscriptions","organizations_url":"https://api.github.com/users/hooverlunch/orgs","repos_url":"https://api.github.com/users/hooverlunch/repos","events_url":"https://api.github.com/users/hooverlunch/events{/privacy}","received_events_url":"https://api.github.com/users/hooverlunch/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-03-17T18:45:06Z","updated_at":"2015-03-19T15:53:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"af0b4edac8ed6e7fba7ea38fe3dd761e1025b972","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/thecartercenter/elmo/pulls/51/commits","review_comments_url":"https://api.github.com/repos/thecartercenter/elmo/pulls/51/comments","review_comment_url":"https://api.github.com/repos/thecartercenter/elmo/pulls/comments{/number}","comments_url":"https://api.github.com/repos/thecartercenter/elmo/issues/51/comments","statuses_url":"https://api.github.com/repos/thecartercenter/elmo/statuses/b25d3c766827cd5efab73547359c0ebe8d29922c","head":{"label":"thecartercenter:2104_upgrade_to_rails_4","ref":"2104_upgrade_to_rails_4","sha":"b25d3c766827cd5efab73547359c0ebe8d29922c","user":{"login":"thecartercenter","id":5075178,"avatar_url":"https://avatars.githubusercontent.com/u/5075178?v=3","gravatar_id":"","url":"https://api.github.com/users/thecartercenter","html_url":"https://github.com/thecartercenter","followers_url":"https://api.github.com/users/thecartercenter/followers","following_url":"https://api.github.com/users/thecartercenter/following{/other_user}","gists_url":"https://api.github.com/users/thecartercenter/gists{/gist_id}","starred_url":"https://api.github.com/users/thecartercenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thecartercenter/subscriptions","organizations_url":"https://api.github.com/users/thecartercenter/orgs","repos_url":"https://api.github.com/users/thecartercenter/repos","events_url":"https://api.github.com/users/thecartercenter/events{/privacy}","received_events_url":"https://api.github.com/users/thecartercenter/received_events","type":"Organization","site_admin":false},"repo":{"id":11615188,"name":"elmo","full_name":"thecartercenter/elmo","owner":{"login":"thecartercenter","id":5075178,"avatar_url":"https://avatars.githubusercontent.com/u/5075178?v=3","gravatar_id":"","url":"https://api.github.com/users/thecartercenter","html_url":"https://github.com/thecartercenter","followers_url":"https://api.github.com/users/thecartercenter/followers","following_url":"https://api.github.com/users/thecartercenter/following{/other_user}","gists_url":"https://api.github.com/users/thecartercenter/gists{/gist_id}","starred_url":"https://api.github.com/users/thecartercenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thecartercenter/subscriptions","organizations_url":"https://api.github.com/users/thecartercenter/orgs","repos_url":"https://api.github.com/users/thecartercenter/repos","events_url":"https://api.github.com/users/thecartercenter/events{/privacy}","received_events_url":"https://api.github.com/users/thecartercenter/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/thecartercenter/elmo","description":"","fork":false,"url":"https://api.github.com/repos/thecartercenter/elmo","forks_url":"https://api.github.com/repos/thecartercenter/elmo/forks","keys_url":"https://api.github.com/repos/thecartercenter/elmo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/thecartercenter/elmo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/thecartercenter/elmo/teams","hooks_url":"https://api.github.com/repos/thecartercenter/elmo/hooks","issue_events_url":"https://api.github.com/repos/thecartercenter/elmo/issues/events{/number}","events_url":"https://api.github.com/repos/thecartercenter/elmo/events","assignees_url":"https://api.github.com/repos/thecartercenter/elmo/assignees{/user}","branches_url":"https://api.github.com/repos/thecartercenter/elmo/branches{/branch}","tags_url":"https://api.github.com/repos/thecartercenter/elmo/tags","blobs_url":"https://api.github.com/repos/thecartercenter/elmo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/thecartercenter/elmo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/thecartercenter/elmo/git/refs{/sha}","trees_url":"https://api.github.com/repos/thecartercenter/elmo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/thecartercenter/elmo/statuses/{sha}","languages_url":"https://api.github.com/repos/thecartercenter/elmo/languages","stargazers_url":"https://api.github.com/repos/thecartercenter/elmo/stargazers","contributors_url":"https://api.github.com/repos/thecartercenter/elmo/contributors","subscribers_url":"https://api.github.com/repos/thecartercenter/elmo/subscribers","subscription_url":"https://api.github.com/repos/thecartercenter/elmo/subscription","commits_url":"https://api.github.com/repos/thecartercenter/elmo/commits{/sha}","git_commits_url":"https://api.github.com/repos/thecartercenter/elmo/git/commits{/sha}","comments_url":"https://api.github.com/repos/thecartercenter/elmo/comments{/number}","issue_comment_url":"https://api.github.com/repos/thecartercenter/elmo/issues/comments{/number}","contents_url":"https://api.github.com/repos/thecartercenter/elmo/contents/{+path}","compare_url":"https://api.github.com/repos/thecartercenter/elmo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/thecartercenter/elmo/merges","archive_url":"https://api.github.com/repos/thecartercenter/elmo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/thecartercenter/elmo/downloads","issues_url":"https://api.github.com/repos/thecartercenter/elmo/issues{/number}","pulls_url":"https://api.github.com/repos/thecartercenter/elmo/pulls{/number}","milestones_url":"https://api.github.com/repos/thecartercenter/elmo/milestones{/number}","notifications_url":"https://api.github.com/repos/thecartercenter/elmo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/thecartercenter/elmo/labels{/name}","releases_url":"https://api.github.com/repos/thecartercenter/elmo/releases{/id}","created_at":"2013-07-23T17:56:04Z","updated_at":"2015-03-06T16:53:05Z","pushed_at":"2015-03-19T15:48:55Z","git_url":"git://github.com/thecartercenter/elmo.git","ssh_url":"git@github.com:thecartercenter/elmo.git","clone_url":"https://github.com/thecartercenter/elmo.git","svn_url":"https://github.com/thecartercenter/elmo","homepage":null,"size":37084,"stargazers_count":10,"watchers_count":10,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"open_issues_count":3,"forks":12,"open_issues":3,"watchers":10,"default_branch":"master"}},"base":{"label":"thecartercenter:develop","ref":"develop","sha":"f980b5db889dc8181cac093a7369d56920ebe6e0","user":{"login":"thecartercenter","id":5075178,"avatar_url":"https://avatars.githubusercontent.com/u/5075178?v=3","gravatar_id":"","url":"https://api.github.com/users/thecartercenter","html_url":"https://github.com/thecartercenter","followers_url":"https://api.github.com/users/thecartercenter/followers","following_url":"https://api.github.com/users/thecartercenter/following{/other_user}","gists_url":"https://api.github.com/users/thecartercenter/gists{/gist_id}","starred_url":"https://api.github.com/users/thecartercenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thecartercenter/subscriptions","organizations_url":"https://api.github.com/users/thecartercenter/orgs","repos_url":"https://api.github.com/users/thecartercenter/repos","events_url":"https://api.github.com/users/thecartercenter/events{/privacy}","received_events_url":"https://api.github.com/users/thecartercenter/received_events","type":"Organization","site_admin":false},"repo":{"id":11615188,"name":"elmo","full_name":"thecartercenter/elmo","owner":{"login":"thecartercenter","id":5075178,"avatar_url":"https://avatars.githubusercontent.com/u/5075178?v=3","gravatar_id":"","url":"https://api.github.com/users/thecartercenter","html_url":"https://github.com/thecartercenter","followers_url":"https://api.github.com/users/thecartercenter/followers","following_url":"https://api.github.com/users/thecartercenter/following{/other_user}","gists_url":"https://api.github.com/users/thecartercenter/gists{/gist_id}","starred_url":"https://api.github.com/users/thecartercenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thecartercenter/subscriptions","organizations_url":"https://api.github.com/users/thecartercenter/orgs","repos_url":"https://api.github.com/users/thecartercenter/repos","events_url":"https://api.github.com/users/thecartercenter/events{/privacy}","received_events_url":"https://api.github.com/users/thecartercenter/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/thecartercenter/elmo","description":"","fork":false,"url":"https://api.github.com/repos/thecartercenter/elmo","forks_url":"https://api.github.com/repos/thecartercenter/elmo/forks","keys_url":"https://api.github.com/repos/thecartercenter/elmo/keys{/key_id}","collaborators_url":"https://api.github.com/repos/thecartercenter/elmo/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/thecartercenter/elmo/teams","hooks_url":"https://api.github.com/repos/thecartercenter/elmo/hooks","issue_events_url":"https://api.github.com/repos/thecartercenter/elmo/issues/events{/number}","events_url":"https://api.github.com/repos/thecartercenter/elmo/events","assignees_url":"https://api.github.com/repos/thecartercenter/elmo/assignees{/user}","branches_url":"https://api.github.com/repos/thecartercenter/elmo/branches{/branch}","tags_url":"https://api.github.com/repos/thecartercenter/elmo/tags","blobs_url":"https://api.github.com/repos/thecartercenter/elmo/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/thecartercenter/elmo/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/thecartercenter/elmo/git/refs{/sha}","trees_url":"https://api.github.com/repos/thecartercenter/elmo/git/trees{/sha}","statuses_url":"https://api.github.com/repos/thecartercenter/elmo/statuses/{sha}","languages_url":"https://api.github.com/repos/thecartercenter/elmo/languages","stargazers_url":"https://api.github.com/repos/thecartercenter/elmo/stargazers","contributors_url":"https://api.github.com/repos/thecartercenter/elmo/contributors","subscribers_url":"https://api.github.com/repos/thecartercenter/elmo/subscribers","subscription_url":"https://api.github.com/repos/thecartercenter/elmo/subscription","commits_url":"https://api.github.com/repos/thecartercenter/elmo/commits{/sha}","git_commits_url":"https://api.github.com/repos/thecartercenter/elmo/git/commits{/sha}","comments_url":"https://api.github.com/repos/thecartercenter/elmo/comments{/number}","issue_comment_url":"https://api.github.com/repos/thecartercenter/elmo/issues/comments{/number}","contents_url":"https://api.github.com/repos/thecartercenter/elmo/contents/{+path}","compare_url":"https://api.github.com/repos/thecartercenter/elmo/compare/{base}...{head}","merges_url":"https://api.github.com/repos/thecartercenter/elmo/merges","archive_url":"https://api.github.com/repos/thecartercenter/elmo/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/thecartercenter/elmo/downloads","issues_url":"https://api.github.com/repos/thecartercenter/elmo/issues{/number}","pulls_url":"https://api.github.com/repos/thecartercenter/elmo/pulls{/number}","milestones_url":"https://api.github.com/repos/thecartercenter/elmo/milestones{/number}","notifications_url":"https://api.github.com/repos/thecartercenter/elmo/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/thecartercenter/elmo/labels{/name}","releases_url":"https://api.github.com/repos/thecartercenter/elmo/releases{/id}","created_at":"2013-07-23T17:56:04Z","updated_at":"2015-03-06T16:53:05Z","pushed_at":"2015-03-19T15:48:55Z","git_url":"git://github.com/thecartercenter/elmo.git","ssh_url":"git@github.com:thecartercenter/elmo.git","clone_url":"https://github.com/thecartercenter/elmo.git","svn_url":"https://github.com/thecartercenter/elmo","homepage":null,"size":37084,"stargazers_count":10,"watchers_count":10,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12,"mirror_url":null,"open_issues_count":3,"forks":12,"open_issues":3,"watchers":10,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/thecartercenter/elmo/pulls/51"},"html":{"href":"https://github.com/thecartercenter/elmo/pull/51"},"issue":{"href":"https://api.github.com/repos/thecartercenter/elmo/issues/51"},"comments":{"href":"https://api.github.com/repos/thecartercenter/elmo/issues/51/comments"},"review_comments":{"href":"https://api.github.com/repos/thecartercenter/elmo/pulls/51/comments"},"review_comment":{"href":"https://api.github.com/repos/thecartercenter/elmo/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/thecartercenter/elmo/pulls/51/commits"},"statuses":{"href":"https://api.github.com/repos/thecartercenter/elmo/statuses/b25d3c766827cd5efab73547359c0ebe8d29922c"}}}}