{"action":"closed","number":178,"pull_request":{"url":"https://api.github.com/repos/facebook/regenerator/pulls/178","id":29739891,"html_url":"https://github.com/facebook/regenerator/pull/178","diff_url":"https://github.com/facebook/regenerator/pull/178.diff","patch_url":"https://github.com/facebook/regenerator/pull/178.patch","issue_url":"https://api.github.com/repos/facebook/regenerator/issues/178","number":178,"state":"closed","locked":false,"title":"Fix JS hoisting issue by using different var name","user":{"login":"xaka","id":504813,"avatar_url":"https://avatars.githubusercontent.com/u/504813?v=3","gravatar_id":"","url":"https://api.github.com/users/xaka","html_url":"https://github.com/xaka","followers_url":"https://api.github.com/users/xaka/followers","following_url":"https://api.github.com/users/xaka/following{/other_user}","gists_url":"https://api.github.com/users/xaka/gists{/gist_id}","starred_url":"https://api.github.com/users/xaka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xaka/subscriptions","organizations_url":"https://api.github.com/users/xaka/orgs","repos_url":"https://api.github.com/users/xaka/repos","events_url":"https://api.github.com/users/xaka/events{/privacy}","received_events_url":"https://api.github.com/users/xaka/received_events","type":"User","site_admin":false},"body":"This is the fix for bug introduced by https://github.com/facebook/regenerator/pull/177. Code reads file in sync way and it assumes `path` variable is pointing to `path` module, but as there is another `path` declaration within the same scope (`var path = new types.NodePath(ast);`), it gets hoisted on top and so `path` becomes `undefined`. It leads to following JS error:\r\n\r\n```\r\nTypeError: Cannot call method 'join' of undefined\r\n```","created_at":"2015-02-20T23:14:19Z","updated_at":"2015-02-21T00:43:42Z","closed_at":"2015-02-21T00:43:42Z","merged_at":"2015-02-21T00:43:42Z","merge_commit_sha":"0a9f7db300f159d85f4a2226a54d562cee65fed2","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/facebook/regenerator/pulls/178/commits","review_comments_url":"https://api.github.com/repos/facebook/regenerator/pulls/178/comments","review_comment_url":"https://api.github.com/repos/facebook/regenerator/pulls/comments/{number}","comments_url":"https://api.github.com/repos/facebook/regenerator/issues/178/comments","statuses_url":"https://api.github.com/repos/facebook/regenerator/statuses/d965625fc5b99d53456026a742d1eaa185841e00","head":{"label":"xaka:patch-1","ref":"patch-1","sha":"d965625fc5b99d53456026a742d1eaa185841e00","user":{"login":"xaka","id":504813,"avatar_url":"https://avatars.githubusercontent.com/u/504813?v=3","gravatar_id":"","url":"https://api.github.com/users/xaka","html_url":"https://github.com/xaka","followers_url":"https://api.github.com/users/xaka/followers","following_url":"https://api.github.com/users/xaka/following{/other_user}","gists_url":"https://api.github.com/users/xaka/gists{/gist_id}","starred_url":"https://api.github.com/users/xaka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xaka/subscriptions","organizations_url":"https://api.github.com/users/xaka/orgs","repos_url":"https://api.github.com/users/xaka/repos","events_url":"https://api.github.com/users/xaka/events{/privacy}","received_events_url":"https://api.github.com/users/xaka/received_events","type":"User","site_admin":false},"repo":{"id":31089779,"name":"regenerator","full_name":"xaka/regenerator","owner":{"login":"xaka","id":504813,"avatar_url":"https://avatars.githubusercontent.com/u/504813?v=3","gravatar_id":"","url":"https://api.github.com/users/xaka","html_url":"https://github.com/xaka","followers_url":"https://api.github.com/users/xaka/followers","following_url":"https://api.github.com/users/xaka/following{/other_user}","gists_url":"https://api.github.com/users/xaka/gists{/gist_id}","starred_url":"https://api.github.com/users/xaka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xaka/subscriptions","organizations_url":"https://api.github.com/users/xaka/orgs","repos_url":"https://api.github.com/users/xaka/repos","events_url":"https://api.github.com/users/xaka/events{/privacy}","received_events_url":"https://api.github.com/users/xaka/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/xaka/regenerator","description":"Source transformer enabling ECMAScript 6 generator functions in JavaScript-of-today.","fork":true,"url":"https://api.github.com/repos/xaka/regenerator","forks_url":"https://api.github.com/repos/xaka/regenerator/forks","keys_url":"https://api.github.com/repos/xaka/regenerator/keys{/key_id}","collaborators_url":"https://api.github.com/repos/xaka/regenerator/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/xaka/regenerator/teams","hooks_url":"https://api.github.com/repos/xaka/regenerator/hooks","issue_events_url":"https://api.github.com/repos/xaka/regenerator/issues/events{/number}","events_url":"https://api.github.com/repos/xaka/regenerator/events","assignees_url":"https://api.github.com/repos/xaka/regenerator/assignees{/user}","branches_url":"https://api.github.com/repos/xaka/regenerator/branches{/branch}","tags_url":"https://api.github.com/repos/xaka/regenerator/tags","blobs_url":"https://api.github.com/repos/xaka/regenerator/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/xaka/regenerator/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/xaka/regenerator/git/refs{/sha}","trees_url":"https://api.github.com/repos/xaka/regenerator/git/trees{/sha}","statuses_url":"https://api.github.com/repos/xaka/regenerator/statuses/{sha}","languages_url":"https://api.github.com/repos/xaka/regenerator/languages","stargazers_url":"https://api.github.com/repos/xaka/regenerator/stargazers","contributors_url":"https://api.github.com/repos/xaka/regenerator/contributors","subscribers_url":"https://api.github.com/repos/xaka/regenerator/subscribers","subscription_url":"https://api.github.com/repos/xaka/regenerator/subscription","commits_url":"https://api.github.com/repos/xaka/regenerator/commits{/sha}","git_commits_url":"https://api.github.com/repos/xaka/regenerator/git/commits{/sha}","comments_url":"https://api.github.com/repos/xaka/regenerator/comments{/number}","issue_comment_url":"https://api.github.com/repos/xaka/regenerator/issues/comments/{number}","contents_url":"https://api.github.com/repos/xaka/regenerator/contents/{+path}","compare_url":"https://api.github.com/repos/xaka/regenerator/compare/{base}...{head}","merges_url":"https://api.github.com/repos/xaka/regenerator/merges","archive_url":"https://api.github.com/repos/xaka/regenerator/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/xaka/regenerator/downloads","issues_url":"https://api.github.com/repos/xaka/regenerator/issues{/number}","pulls_url":"https://api.github.com/repos/xaka/regenerator/pulls{/number}","milestones_url":"https://api.github.com/repos/xaka/regenerator/milestones{/number}","notifications_url":"https://api.github.com/repos/xaka/regenerator/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/xaka/regenerator/labels{/name}","releases_url":"https://api.github.com/repos/xaka/regenerator/releases{/id}","created_at":"2015-02-20T23:12:27Z","updated_at":"2015-02-20T23:12:27Z","pushed_at":"2015-02-20T23:13:57Z","git_url":"git://github.com/xaka/regenerator.git","ssh_url":"git@github.com:xaka/regenerator.git","clone_url":"https://github.com/xaka/regenerator.git","svn_url":"https://github.com/xaka/regenerator","homepage":"http://facebook.github.io/regenerator/","size":4253,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"facebook:master","ref":"master","sha":"24491653a2a46a0f29ddcc5e5c8408a4338828ab","user":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"repo":{"id":13346571,"name":"regenerator","full_name":"facebook/regenerator","owner":{"login":"facebook","id":69631,"avatar_url":"https://avatars.githubusercontent.com/u/69631?v=3","gravatar_id":"","url":"https://api.github.com/users/facebook","html_url":"https://github.com/facebook","followers_url":"https://api.github.com/users/facebook/followers","following_url":"https://api.github.com/users/facebook/following{/other_user}","gists_url":"https://api.github.com/users/facebook/gists{/gist_id}","starred_url":"https://api.github.com/users/facebook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/facebook/subscriptions","organizations_url":"https://api.github.com/users/facebook/orgs","repos_url":"https://api.github.com/users/facebook/repos","events_url":"https://api.github.com/users/facebook/events{/privacy}","received_events_url":"https://api.github.com/users/facebook/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/facebook/regenerator","description":"Source transformer enabling ECMAScript 6 generator functions in JavaScript-of-today.","fork":false,"url":"https://api.github.com/repos/facebook/regenerator","forks_url":"https://api.github.com/repos/facebook/regenerator/forks","keys_url":"https://api.github.com/repos/facebook/regenerator/keys{/key_id}","collaborators_url":"https://api.github.com/repos/facebook/regenerator/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/facebook/regenerator/teams","hooks_url":"https://api.github.com/repos/facebook/regenerator/hooks","issue_events_url":"https://api.github.com/repos/facebook/regenerator/issues/events{/number}","events_url":"https://api.github.com/repos/facebook/regenerator/events","assignees_url":"https://api.github.com/repos/facebook/regenerator/assignees{/user}","branches_url":"https://api.github.com/repos/facebook/regenerator/branches{/branch}","tags_url":"https://api.github.com/repos/facebook/regenerator/tags","blobs_url":"https://api.github.com/repos/facebook/regenerator/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/facebook/regenerator/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/facebook/regenerator/git/refs{/sha}","trees_url":"https://api.github.com/repos/facebook/regenerator/git/trees{/sha}","statuses_url":"https://api.github.com/repos/facebook/regenerator/statuses/{sha}","languages_url":"https://api.github.com/repos/facebook/regenerator/languages","stargazers_url":"https://api.github.com/repos/facebook/regenerator/stargazers","contributors_url":"https://api.github.com/repos/facebook/regenerator/contributors","subscribers_url":"https://api.github.com/repos/facebook/regenerator/subscribers","subscription_url":"https://api.github.com/repos/facebook/regenerator/subscription","commits_url":"https://api.github.com/repos/facebook/regenerator/commits{/sha}","git_commits_url":"https://api.github.com/repos/facebook/regenerator/git/commits{/sha}","comments_url":"https://api.github.com/repos/facebook/regenerator/comments{/number}","issue_comment_url":"https://api.github.com/repos/facebook/regenerator/issues/comments/{number}","contents_url":"https://api.github.com/repos/facebook/regenerator/contents/{+path}","compare_url":"https://api.github.com/repos/facebook/regenerator/compare/{base}...{head}","merges_url":"https://api.github.com/repos/facebook/regenerator/merges","archive_url":"https://api.github.com/repos/facebook/regenerator/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/facebook/regenerator/downloads","issues_url":"https://api.github.com/repos/facebook/regenerator/issues{/number}","pulls_url":"https://api.github.com/repos/facebook/regenerator/pulls{/number}","milestones_url":"https://api.github.com/repos/facebook/regenerator/milestones{/number}","notifications_url":"https://api.github.com/repos/facebook/regenerator/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/facebook/regenerator/labels{/name}","releases_url":"https://api.github.com/repos/facebook/regenerator/releases{/id}","created_at":"2013-10-05T14:37:03Z","updated_at":"2015-02-20T22:17:17Z","pushed_at":"2015-02-21T00:43:42Z","git_url":"git://github.com/facebook/regenerator.git","ssh_url":"git@github.com:facebook/regenerator.git","clone_url":"https://github.com/facebook/regenerator.git","svn_url":"https://github.com/facebook/regenerator","homepage":"http://facebook.github.io/regenerator/","size":4253,"stargazers_count":1033,"watchers_count":1033,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":85,"mirror_url":null,"open_issues_count":18,"forks":85,"open_issues":18,"watchers":1033,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/facebook/regenerator/pulls/178"},"html":{"href":"https://github.com/facebook/regenerator/pull/178"},"issue":{"href":"https://api.github.com/repos/facebook/regenerator/issues/178"},"comments":{"href":"https://api.github.com/repos/facebook/regenerator/issues/178/comments"},"review_comments":{"href":"https://api.github.com/repos/facebook/regenerator/pulls/178/comments"},"review_comment":{"href":"https://api.github.com/repos/facebook/regenerator/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/facebook/regenerator/pulls/178/commits"},"statuses":{"href":"https://api.github.com/repos/facebook/regenerator/statuses/d965625fc5b99d53456026a742d1eaa185841e00"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"benjamn","id":5750,"avatar_url":"https://avatars.githubusercontent.com/u/5750?v=3","gravatar_id":"","url":"https://api.github.com/users/benjamn","html_url":"https://github.com/benjamn","followers_url":"https://api.github.com/users/benjamn/followers","following_url":"https://api.github.com/users/benjamn/following{/other_user}","gists_url":"https://api.github.com/users/benjamn/gists{/gist_id}","starred_url":"https://api.github.com/users/benjamn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benjamn/subscriptions","organizations_url":"https://api.github.com/users/benjamn/orgs","repos_url":"https://api.github.com/users/benjamn/repos","events_url":"https://api.github.com/users/benjamn/events{/privacy}","received_events_url":"https://api.github.com/users/benjamn/received_events","type":"User","site_admin":false},"comments":3,"review_comments":0,"commits":1,"additions":3,"deletions":3,"changed_files":1}}