{"action":"created","comment":{"url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/comments/44626257","id":44626257,"diff_hunk":"@@ -384,16 +460,25 @@ class Data\n       cur = do cur.getParent\n       if cur.is @viewRoot\n         return answer\n-      if cur.id == @root.id\n+      if do cur.isRoot\n         return null\n       if @collapsed cur\n         answer = cur\n \n+  wouldBeCircularInsertTree: (row, parent) ->\n+    # Precondition: tree is not already circular\n+    # Rather than checking for each descendent, whether that descendent is an ancestor (old method)\n+    # Instead, check if the row is an ancestor of the new parent, which is sufficient.\n+    _.contains (@allAncestors parent.id, { inclusive: true }), row.id","path":"assets/js/data.coffee","position":285,"original_position":285,"commit_id":"0fc7e6a527017a377e7bc2463105e221ccad9a07","original_commit_id":"0fc7e6a527017a377e7bc2463105e221ccad9a07","user":{"login":"WuTheFWasThat","id":1479648,"avatar_url":"https://avatars.githubusercontent.com/u/1479648?v=3","gravatar_id":"","url":"https://api.github.com/users/WuTheFWasThat","html_url":"https://github.com/WuTheFWasThat","followers_url":"https://api.github.com/users/WuTheFWasThat/followers","following_url":"https://api.github.com/users/WuTheFWasThat/following{/other_user}","gists_url":"https://api.github.com/users/WuTheFWasThat/gists{/gist_id}","starred_url":"https://api.github.com/users/WuTheFWasThat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WuTheFWasThat/subscriptions","organizations_url":"https://api.github.com/users/WuTheFWasThat/orgs","repos_url":"https://api.github.com/users/WuTheFWasThat/repos","events_url":"https://api.github.com/users/WuTheFWasThat/events{/privacy}","received_events_url":"https://api.github.com/users/WuTheFWasThat/received_events","type":"User","site_admin":false},"body":"i think we need to get the set of clones underneath the row, as well, right?  ","created_at":"2015-11-12T06:54:16Z","updated_at":"2015-11-12T06:54:16Z","html_url":"https://github.com/WuTheFWasThat/vimflowy/pull/94#discussion_r44626257","pull_request_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94","_links":{"self":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/comments/44626257"},"html":{"href":"https://github.com/WuTheFWasThat/vimflowy/pull/94#discussion_r44626257"},"pull_request":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94"}}},"pull_request":{"url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94","id":49382258,"html_url":"https://github.com/WuTheFWasThat/vimflowy/pull/94","diff_url":"https://github.com/WuTheFWasThat/vimflowy/pull/94.diff","patch_url":"https://github.com/WuTheFWasThat/vimflowy/pull/94.patch","issue_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/94","number":94,"state":"open","locked":false,"title":"Aliasing","user":{"login":"WuTheFWasThat","id":1479648,"avatar_url":"https://avatars.githubusercontent.com/u/1479648?v=3","gravatar_id":"","url":"https://api.github.com/users/WuTheFWasThat","html_url":"https://github.com/WuTheFWasThat","followers_url":"https://api.github.com/users/WuTheFWasThat/followers","following_url":"https://api.github.com/users/WuTheFWasThat/following{/other_user}","gists_url":"https://api.github.com/users/WuTheFWasThat/gists{/gist_id}","starred_url":"https://api.github.com/users/WuTheFWasThat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WuTheFWasThat/subscriptions","organizations_url":"https://api.github.com/users/WuTheFWasThat/orgs","repos_url":"https://api.github.com/users/WuTheFWasThat/repos","events_url":"https://api.github.com/users/WuTheFWasThat/events{/privacy}","received_events_url":"https://api.github.com/users/WuTheFWasThat/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-11-01T22:07:49Z","updated_at":"2015-11-12T06:54:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ab5ef7c6794cebf55f162d038d9a21d33dd2f064","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94/commits","review_comments_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94/comments","review_comment_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/94/comments","statuses_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/statuses/0fc7e6a527017a377e7bc2463105e221ccad9a07","head":{"label":"WuTheFWasThat:aliasing","ref":"aliasing","sha":"0fc7e6a527017a377e7bc2463105e221ccad9a07","user":{"login":"WuTheFWasThat","id":1479648,"avatar_url":"https://avatars.githubusercontent.com/u/1479648?v=3","gravatar_id":"","url":"https://api.github.com/users/WuTheFWasThat","html_url":"https://github.com/WuTheFWasThat","followers_url":"https://api.github.com/users/WuTheFWasThat/followers","following_url":"https://api.github.com/users/WuTheFWasThat/following{/other_user}","gists_url":"https://api.github.com/users/WuTheFWasThat/gists{/gist_id}","starred_url":"https://api.github.com/users/WuTheFWasThat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WuTheFWasThat/subscriptions","organizations_url":"https://api.github.com/users/WuTheFWasThat/orgs","repos_url":"https://api.github.com/users/WuTheFWasThat/repos","events_url":"https://api.github.com/users/WuTheFWasThat/events{/privacy}","received_events_url":"https://api.github.com/users/WuTheFWasThat/received_events","type":"User","site_admin":false},"repo":{"id":35233843,"name":"vimflowy","full_name":"WuTheFWasThat/vimflowy","owner":{"login":"WuTheFWasThat","id":1479648,"avatar_url":"https://avatars.githubusercontent.com/u/1479648?v=3","gravatar_id":"","url":"https://api.github.com/users/WuTheFWasThat","html_url":"https://github.com/WuTheFWasThat","followers_url":"https://api.github.com/users/WuTheFWasThat/followers","following_url":"https://api.github.com/users/WuTheFWasThat/following{/other_user}","gists_url":"https://api.github.com/users/WuTheFWasThat/gists{/gist_id}","starred_url":"https://api.github.com/users/WuTheFWasThat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WuTheFWasThat/subscriptions","organizations_url":"https://api.github.com/users/WuTheFWasThat/orgs","repos_url":"https://api.github.com/users/WuTheFWasThat/repos","events_url":"https://api.github.com/users/WuTheFWasThat/events{/privacy}","received_events_url":"https://api.github.com/users/WuTheFWasThat/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/WuTheFWasThat/vimflowy","description":"","fork":false,"url":"https://api.github.com/repos/WuTheFWasThat/vimflowy","forks_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/forks","keys_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/teams","hooks_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/hooks","issue_events_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/events{/number}","events_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/events","assignees_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/assignees{/user}","branches_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/branches{/branch}","tags_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/tags","blobs_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/refs{/sha}","trees_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/statuses/{sha}","languages_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/languages","stargazers_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/stargazers","contributors_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/contributors","subscribers_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/subscribers","subscription_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/subscription","commits_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/commits{/sha}","git_commits_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/commits{/sha}","comments_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/comments{/number}","issue_comment_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/comments{/number}","contents_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/contents/{+path}","compare_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/merges","archive_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/downloads","issues_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues{/number}","pulls_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls{/number}","milestones_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/milestones{/number}","notifications_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/labels{/name}","releases_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/releases{/id}","created_at":"2015-05-07T17:30:49Z","updated_at":"2015-11-03T15:04:07Z","pushed_at":"2015-11-11T22:21:29Z","git_url":"git://github.com/WuTheFWasThat/vimflowy.git","ssh_url":"git@github.com:WuTheFWasThat/vimflowy.git","clone_url":"https://github.com/WuTheFWasThat/vimflowy.git","svn_url":"https://github.com/WuTheFWasThat/vimflowy","homepage":null,"size":2231,"stargazers_count":11,"watchers_count":11,"language":"CoffeeScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":36,"forks":1,"open_issues":36,"watchers":11,"default_branch":"master"}},"base":{"label":"WuTheFWasThat:master","ref":"master","sha":"760db29f3c6469e6477f86c1cce9024d63802244","user":{"login":"WuTheFWasThat","id":1479648,"avatar_url":"https://avatars.githubusercontent.com/u/1479648?v=3","gravatar_id":"","url":"https://api.github.com/users/WuTheFWasThat","html_url":"https://github.com/WuTheFWasThat","followers_url":"https://api.github.com/users/WuTheFWasThat/followers","following_url":"https://api.github.com/users/WuTheFWasThat/following{/other_user}","gists_url":"https://api.github.com/users/WuTheFWasThat/gists{/gist_id}","starred_url":"https://api.github.com/users/WuTheFWasThat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WuTheFWasThat/subscriptions","organizations_url":"https://api.github.com/users/WuTheFWasThat/orgs","repos_url":"https://api.github.com/users/WuTheFWasThat/repos","events_url":"https://api.github.com/users/WuTheFWasThat/events{/privacy}","received_events_url":"https://api.github.com/users/WuTheFWasThat/received_events","type":"User","site_admin":false},"repo":{"id":35233843,"name":"vimflowy","full_name":"WuTheFWasThat/vimflowy","owner":{"login":"WuTheFWasThat","id":1479648,"avatar_url":"https://avatars.githubusercontent.com/u/1479648?v=3","gravatar_id":"","url":"https://api.github.com/users/WuTheFWasThat","html_url":"https://github.com/WuTheFWasThat","followers_url":"https://api.github.com/users/WuTheFWasThat/followers","following_url":"https://api.github.com/users/WuTheFWasThat/following{/other_user}","gists_url":"https://api.github.com/users/WuTheFWasThat/gists{/gist_id}","starred_url":"https://api.github.com/users/WuTheFWasThat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WuTheFWasThat/subscriptions","organizations_url":"https://api.github.com/users/WuTheFWasThat/orgs","repos_url":"https://api.github.com/users/WuTheFWasThat/repos","events_url":"https://api.github.com/users/WuTheFWasThat/events{/privacy}","received_events_url":"https://api.github.com/users/WuTheFWasThat/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/WuTheFWasThat/vimflowy","description":"","fork":false,"url":"https://api.github.com/repos/WuTheFWasThat/vimflowy","forks_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/forks","keys_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/teams","hooks_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/hooks","issue_events_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/events{/number}","events_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/events","assignees_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/assignees{/user}","branches_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/branches{/branch}","tags_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/tags","blobs_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/refs{/sha}","trees_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/statuses/{sha}","languages_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/languages","stargazers_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/stargazers","contributors_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/contributors","subscribers_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/subscribers","subscription_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/subscription","commits_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/commits{/sha}","git_commits_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/git/commits{/sha}","comments_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/comments{/number}","issue_comment_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/comments{/number}","contents_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/contents/{+path}","compare_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/merges","archive_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/downloads","issues_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues{/number}","pulls_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls{/number}","milestones_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/milestones{/number}","notifications_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/labels{/name}","releases_url":"https://api.github.com/repos/WuTheFWasThat/vimflowy/releases{/id}","created_at":"2015-05-07T17:30:49Z","updated_at":"2015-11-03T15:04:07Z","pushed_at":"2015-11-11T22:21:29Z","git_url":"git://github.com/WuTheFWasThat/vimflowy.git","ssh_url":"git@github.com:WuTheFWasThat/vimflowy.git","clone_url":"https://github.com/WuTheFWasThat/vimflowy.git","svn_url":"https://github.com/WuTheFWasThat/vimflowy","homepage":null,"size":2231,"stargazers_count":11,"watchers_count":11,"language":"CoffeeScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":36,"forks":1,"open_issues":36,"watchers":11,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94"},"html":{"href":"https://github.com/WuTheFWasThat/vimflowy/pull/94"},"issue":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/94"},"comments":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/issues/94/comments"},"review_comments":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94/comments"},"review_comment":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/pulls/94/commits"},"statuses":{"href":"https://api.github.com/repos/WuTheFWasThat/vimflowy/statuses/0fc7e6a527017a377e7bc2463105e221ccad9a07"}}}}