Skip to content

Commit

Permalink
refactor: improve generated code style. (#96)
Browse files Browse the repository at this point in the history
  • Loading branch information
yoshi-automation authored and JustinBeckwith committed Feb 2, 2019
1 parent 689ccb5 commit ddbabed
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 14 deletions.
11 changes: 2 additions & 9 deletions packages/google-cloud-asset/src/v1beta1/asset_service_client.js
Original file line number Diff line number Diff line change
Expand Up @@ -277,20 +277,14 @@ class AssetServiceClient {
* // Handle the operation using the promise pattern.
* client.exportAssets(request)
* .then(responses => {
* const operation = responses[0];
* const initialApiResponse = responses[1];
* const [operation, initialApiResponse] = responses;
*
* // Operation#promise starts polling for the completion of the LRO.
* return operation.promise();
* })
* .then(responses => {
* // The final result of the operation.
* const result = responses[0];
*
* // The metadata value of the completed operation.
* const metadata = responses[1];
*
* // The response of the api call returning the complete operation.
* const finalApiResponse = responses[2];
* })
* .catch(err => {
Expand All @@ -307,8 +301,7 @@ class AssetServiceClient {
* // Handle the operation using the event emitter pattern.
* client.exportAssets(request)
* .then(responses => {
* const operation = responses[0];
* const initialApiResponse = responses[1];
* const [operation, initialApiResponse] = responses;
*
* // Adding a listener for the "complete" event starts polling for the
* // completion of the operation.
Expand Down
10 changes: 5 additions & 5 deletions packages/google-cloud-asset/synth.metadata
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
{
"updateTime": "2019-01-22T12:19:14.185087Z",
"updateTime": "2019-02-02T12:07:39.907100Z",
"sources": [
{
"generator": {
"name": "artman",
"version": "0.16.7",
"dockerImage": "googleapis/artman@sha256:d6c8ced606eb49973ca95d2af7c55a681acc042db0f87d135968349e7bf6dd80"
"version": "0.16.8",
"dockerImage": "googleapis/artman@sha256:75bc07ef34a1de9895c18af54dc503ed3b3f3b52e85062e3360a979d2a0741e7"
}
},
{
"git": {
"name": "googleapis",
"remote": "https://github.com/googleapis/googleapis.git",
"sha": "96adaf6de4fa2cabbdd5de560a367bb488e0639b",
"internalRef": "229998977"
"sha": "bce093dab3e65c40eb9a37efbdc960f34df6037a",
"internalRef": "231974277"
}
},
{
Expand Down

0 comments on commit ddbabed

Please sign in to comment.