{"action":"created","comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments/71095738","id":71095738,"diff_hunk":"@@ -393,14 +393,13 @@ var name = 'ubuntu-http';\n zone.createVM(name, { os: 'ubuntu' }, function(err, vm, operation) {\n   // `operation` lets you check the status of long-running tasks.\n \n-  operation.on('complete', function(err, metadata) {\n-    if (!err) {\n-      // Virtual machine created!\n-    }\n+  operation.on('complete', function(metadata) {\n+    // Virtual machine created!\n   });\n });\n ```\n \n+You can read more about opeation events [here](https://github.com/GoogleCloudPlatform/gcloud-node/blob/276c847669470c3639eb78d7d87a09db7a9b5c18/lib/compute/operation.js#L83).","path":"README.md","position":14,"original_position":14,"commit_id":"f6f720aa8cc7223be97a118b0c863b4493b24ff6","original_commit_id":"f6f720aa8cc7223be97a118b0c863b4493b24ff6","user":{"login":"Gormartsen","id":5018896,"avatar_url":"https://avatars.githubusercontent.com/u/5018896?v=3","gravatar_id":"","url":"https://api.github.com/users/Gormartsen","html_url":"https://github.com/Gormartsen","followers_url":"https://api.github.com/users/Gormartsen/followers","following_url":"https://api.github.com/users/Gormartsen/following{/other_user}","gists_url":"https://api.github.com/users/Gormartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/Gormartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Gormartsen/subscriptions","organizations_url":"https://api.github.com/users/Gormartsen/orgs","repos_url":"https://api.github.com/users/Gormartsen/repos","events_url":"https://api.github.com/users/Gormartsen/events{/privacy}","received_events_url":"https://api.github.com/users/Gormartsen/received_events","type":"User","site_admin":false},"body":"```\r\n  operation\r\n  .on('error', function(err) {})\r\n  .on('running', function(metadata) {})\r\n  .on('complete', function(metadata) {\r\n    // Virtual machine created!\r\n  });\r\n```","created_at":"2016-07-18T02:25:39Z","updated_at":"2016-07-18T02:25:39Z","html_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1437#discussion_r71095738","pull_request_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437","_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments/71095738"},"html":{"href":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1437#discussion_r71095738"},"pull_request":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437"}}},"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437","id":77753879,"html_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1437","diff_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1437.diff","patch_url":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1437.patch","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1437","number":1437,"state":"open","locked":false,"title":"Correct documentation on operation 'complete'","user":{"login":"Gormartsen","id":5018896,"avatar_url":"https://avatars.githubusercontent.com/u/5018896?v=3","gravatar_id":"","url":"https://api.github.com/users/Gormartsen","html_url":"https://github.com/Gormartsen","followers_url":"https://api.github.com/users/Gormartsen/followers","following_url":"https://api.github.com/users/Gormartsen/following{/other_user}","gists_url":"https://api.github.com/users/Gormartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/Gormartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Gormartsen/subscriptions","organizations_url":"https://api.github.com/users/Gormartsen/orgs","repos_url":"https://api.github.com/users/Gormartsen/repos","events_url":"https://api.github.com/users/Gormartsen/events{/privacy}","received_events_url":"https://api.github.com/users/Gormartsen/received_events","type":"User","site_admin":false},"body":"Relate to #1432\r\n\r\n@stephenplusplus My pardon! \r\noperation.on('complete') return metadata only. THere is no err value.\r\n\r\nI decided to add link to code where all operations emits described.\r\n\r\nFeel free to request updates to this PR. No offence here.","created_at":"2016-07-18T02:15:27Z","updated_at":"2016-07-18T02:25:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6671f5af4c6938ddf6a5b8cb0ca6e865e5867484","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437/commits","review_comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437/comments","review_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1437/comments","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/statuses/f6f720aa8cc7223be97a118b0c863b4493b24ff6","head":{"label":"Gormartsen:patch-1","ref":"patch-1","sha":"f6f720aa8cc7223be97a118b0c863b4493b24ff6","user":{"login":"Gormartsen","id":5018896,"avatar_url":"https://avatars.githubusercontent.com/u/5018896?v=3","gravatar_id":"","url":"https://api.github.com/users/Gormartsen","html_url":"https://github.com/Gormartsen","followers_url":"https://api.github.com/users/Gormartsen/followers","following_url":"https://api.github.com/users/Gormartsen/following{/other_user}","gists_url":"https://api.github.com/users/Gormartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/Gormartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Gormartsen/subscriptions","organizations_url":"https://api.github.com/users/Gormartsen/orgs","repos_url":"https://api.github.com/users/Gormartsen/repos","events_url":"https://api.github.com/users/Gormartsen/events{/privacy}","received_events_url":"https://api.github.com/users/Gormartsen/received_events","type":"User","site_admin":false},"repo":{"id":63563061,"name":"gcloud-node","full_name":"Gormartsen/gcloud-node","owner":{"login":"Gormartsen","id":5018896,"avatar_url":"https://avatars.githubusercontent.com/u/5018896?v=3","gravatar_id":"","url":"https://api.github.com/users/Gormartsen","html_url":"https://github.com/Gormartsen","followers_url":"https://api.github.com/users/Gormartsen/followers","following_url":"https://api.github.com/users/Gormartsen/following{/other_user}","gists_url":"https://api.github.com/users/Gormartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/Gormartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Gormartsen/subscriptions","organizations_url":"https://api.github.com/users/Gormartsen/orgs","repos_url":"https://api.github.com/users/Gormartsen/repos","events_url":"https://api.github.com/users/Gormartsen/events{/privacy}","received_events_url":"https://api.github.com/users/Gormartsen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Gormartsen/gcloud-node","description":"Google Cloud Client Library for Node.js","fork":true,"url":"https://api.github.com/repos/Gormartsen/gcloud-node","forks_url":"https://api.github.com/repos/Gormartsen/gcloud-node/forks","keys_url":"https://api.github.com/repos/Gormartsen/gcloud-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Gormartsen/gcloud-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Gormartsen/gcloud-node/teams","hooks_url":"https://api.github.com/repos/Gormartsen/gcloud-node/hooks","issue_events_url":"https://api.github.com/repos/Gormartsen/gcloud-node/issues/events{/number}","events_url":"https://api.github.com/repos/Gormartsen/gcloud-node/events","assignees_url":"https://api.github.com/repos/Gormartsen/gcloud-node/assignees{/user}","branches_url":"https://api.github.com/repos/Gormartsen/gcloud-node/branches{/branch}","tags_url":"https://api.github.com/repos/Gormartsen/gcloud-node/tags","blobs_url":"https://api.github.com/repos/Gormartsen/gcloud-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Gormartsen/gcloud-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Gormartsen/gcloud-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/Gormartsen/gcloud-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Gormartsen/gcloud-node/statuses/{sha}","languages_url":"https://api.github.com/repos/Gormartsen/gcloud-node/languages","stargazers_url":"https://api.github.com/repos/Gormartsen/gcloud-node/stargazers","contributors_url":"https://api.github.com/repos/Gormartsen/gcloud-node/contributors","subscribers_url":"https://api.github.com/repos/Gormartsen/gcloud-node/subscribers","subscription_url":"https://api.github.com/repos/Gormartsen/gcloud-node/subscription","commits_url":"https://api.github.com/repos/Gormartsen/gcloud-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/Gormartsen/gcloud-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/Gormartsen/gcloud-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/Gormartsen/gcloud-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/Gormartsen/gcloud-node/contents/{+path}","compare_url":"https://api.github.com/repos/Gormartsen/gcloud-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Gormartsen/gcloud-node/merges","archive_url":"https://api.github.com/repos/Gormartsen/gcloud-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Gormartsen/gcloud-node/downloads","issues_url":"https://api.github.com/repos/Gormartsen/gcloud-node/issues{/number}","pulls_url":"https://api.github.com/repos/Gormartsen/gcloud-node/pulls{/number}","milestones_url":"https://api.github.com/repos/Gormartsen/gcloud-node/milestones{/number}","notifications_url":"https://api.github.com/repos/Gormartsen/gcloud-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Gormartsen/gcloud-node/labels{/name}","releases_url":"https://api.github.com/repos/Gormartsen/gcloud-node/releases{/id}","deployments_url":"https://api.github.com/repos/Gormartsen/gcloud-node/deployments","created_at":"2016-07-18T02:10:15Z","updated_at":"2016-07-18T02:10:17Z","pushed_at":"2016-07-18T02:13:01Z","git_url":"git://github.com/Gormartsen/gcloud-node.git","ssh_url":"git@github.com:Gormartsen/gcloud-node.git","clone_url":"https://github.com/Gormartsen/gcloud-node.git","svn_url":"https://github.com/Gormartsen/gcloud-node","homepage":"https://googlecloudplatform.github.io/gcloud-node/","size":17086,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"GoogleCloudPlatform:master","ref":"master","sha":"470fc3d465c73e44e597ff795e75ae329cac9691","user":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"repo":{"id":19483273,"name":"gcloud-node","full_name":"GoogleCloudPlatform/gcloud-node","owner":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars.githubusercontent.com/u/2810941?v=3","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GoogleCloudPlatform/gcloud-node","description":"Google Cloud Client Library for Node.js","fork":false,"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node","forks_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/forks","keys_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/teams","hooks_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/hooks","issue_events_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/events{/number}","events_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/events","assignees_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/assignees{/user}","branches_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/branches{/branch}","tags_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/tags","blobs_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/refs{/sha}","trees_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/statuses/{sha}","languages_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/languages","stargazers_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/stargazers","contributors_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/contributors","subscribers_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/subscribers","subscription_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/subscription","commits_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/commits{/sha}","git_commits_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/git/commits{/sha}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/comments{/number}","issue_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/comments{/number}","contents_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/contents/{+path}","compare_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/merges","archive_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/downloads","issues_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues{/number}","pulls_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls{/number}","milestones_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/milestones{/number}","notifications_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/labels{/name}","releases_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/releases{/id}","deployments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/deployments","created_at":"2014-05-06T06:18:00Z","updated_at":"2016-07-17T08:10:53Z","pushed_at":"2016-07-18T02:15:27Z","git_url":"git://github.com/GoogleCloudPlatform/gcloud-node.git","ssh_url":"git@github.com:GoogleCloudPlatform/gcloud-node.git","clone_url":"https://github.com/GoogleCloudPlatform/gcloud-node.git","svn_url":"https://github.com/GoogleCloudPlatform/gcloud-node","homepage":"https://googlecloudplatform.github.io/gcloud-node/","size":17086,"stargazers_count":845,"watchers_count":845,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":182,"mirror_url":null,"open_issues_count":49,"forks":182,"open_issues":49,"watchers":845,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437"},"html":{"href":"https://github.com/GoogleCloudPlatform/gcloud-node/pull/1437"},"issue":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1437"},"comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/1437/comments"},"review_comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437/comments"},"review_comment":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/pulls/1437/commits"},"statuses":{"href":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/statuses/f6f720aa8cc7223be97a118b0c863b4493b24ff6"}}}}
{"actor":{"display_login":"Gormartsen"}}