Skip to content

Commit

Permalink
Switch to let/const (#169)
Browse files Browse the repository at this point in the history
  • Loading branch information
dpebot authored and JustinBeckwith committed Sep 14, 2018
1 parent ae8bc53 commit 8028bf3
Show file tree
Hide file tree
Showing 15 changed files with 242 additions and 242 deletions.
18 changes: 9 additions & 9 deletions packages/google-cloud-node/smoke-test/speech_smoke_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,29 +18,29 @@ describe('SpeechSmokeTest', () => {
it('successfully makes a call to the service', done => {
const speech = require('../src');

var client = new speech.v1p1beta1.SpeechClient({
const client = new speech.v1p1beta1.SpeechClient({
// optional auth parameters.
});

var languageCode = 'en-US';
var sampleRateHertz = 44100;
var encoding = 'FLAC';
var config = {
const languageCode = 'en-US';
const sampleRateHertz = 44100;
const encoding = 'FLAC';
const config = {
languageCode: languageCode,
sampleRateHertz: sampleRateHertz,
encoding: encoding,
};
var uri = 'gs://gapic-toolkit/hello.flac';
var audio = {
const uri = 'gs://gapic-toolkit/hello.flac';
const audio = {
uri: uri,
};
var request = {
const request = {
config: config,
audio: audio,
};
client.recognize(request)
.then(responses => {
var response = responses[0];
const response = responses[0];
console.log(response);
})
.then(done)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.RecognizeRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var RecognizeRequest = {
const RecognizeRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -56,7 +56,7 @@ var RecognizeRequest = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.LongRunningRecognizeRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var LongRunningRecognizeRequest = {
const LongRunningRecognizeRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -88,7 +88,7 @@ var LongRunningRecognizeRequest = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.StreamingRecognizeRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var StreamingRecognizeRequest = {
const StreamingRecognizeRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -125,7 +125,7 @@ var StreamingRecognizeRequest = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.StreamingRecognitionConfig definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var StreamingRecognitionConfig = {
const StreamingRecognitionConfig = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -243,7 +243,7 @@ var StreamingRecognitionConfig = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.RecognitionConfig definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var RecognitionConfig = {
const RecognitionConfig = {
// This is for documentation. Actual contents will be loaded by gRPC.

/**
Expand Down Expand Up @@ -350,7 +350,7 @@ var RecognitionConfig = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.SpeechContext definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var SpeechContext = {
const SpeechContext = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -378,7 +378,7 @@ var SpeechContext = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.RecognitionAudio definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var RecognitionAudio = {
const RecognitionAudio = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -397,7 +397,7 @@ var RecognitionAudio = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.RecognizeResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var RecognizeResponse = {
const RecognizeResponse = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -418,7 +418,7 @@ var RecognizeResponse = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.LongRunningRecognizeResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var LongRunningRecognizeResponse = {
const LongRunningRecognizeResponse = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -445,7 +445,7 @@ var LongRunningRecognizeResponse = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.LongRunningRecognizeMetadata definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var LongRunningRecognizeMetadata = {
const LongRunningRecognizeMetadata = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -523,7 +523,7 @@ var LongRunningRecognizeMetadata = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.StreamingRecognizeResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var StreamingRecognizeResponse = {
const StreamingRecognizeResponse = {
// This is for documentation. Actual contents will be loaded by gRPC.

/**
Expand Down Expand Up @@ -582,7 +582,7 @@ var StreamingRecognizeResponse = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.StreamingRecognitionResult definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var StreamingRecognitionResult = {
const StreamingRecognitionResult = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -601,7 +601,7 @@ var StreamingRecognitionResult = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.SpeechRecognitionResult definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var SpeechRecognitionResult = {
const SpeechRecognitionResult = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -629,7 +629,7 @@ var SpeechRecognitionResult = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.SpeechRecognitionAlternative definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var SpeechRecognitionAlternative = {
const SpeechRecognitionAlternative = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand Down Expand Up @@ -663,6 +663,6 @@ var SpeechRecognitionAlternative = {
* @memberof google.cloud.speech.v1
* @see [google.cloud.speech.v1.WordInfo definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/cloud/speech/v1/cloud_speech.proto}
*/
var WordInfo = {
const WordInfo = {
// This is for documentation. Actual contents will be loaded by gRPC.
};
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
* @memberof google.longrunning
* @see [google.longrunning.Operation definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto}
*/
var Operation = {
const Operation = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -72,7 +72,7 @@ var Operation = {
* @memberof google.longrunning
* @see [google.longrunning.GetOperationRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto}
*/
var GetOperationRequest = {
const GetOperationRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -95,7 +95,7 @@ var GetOperationRequest = {
* @memberof google.longrunning
* @see [google.longrunning.ListOperationsRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto}
*/
var ListOperationsRequest = {
const ListOperationsRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -114,7 +114,7 @@ var ListOperationsRequest = {
* @memberof google.longrunning
* @see [google.longrunning.ListOperationsResponse definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto}
*/
var ListOperationsResponse = {
const ListOperationsResponse = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -128,7 +128,7 @@ var ListOperationsResponse = {
* @memberof google.longrunning
* @see [google.longrunning.CancelOperationRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto}
*/
var CancelOperationRequest = {
const CancelOperationRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};

Expand All @@ -142,6 +142,6 @@ var CancelOperationRequest = {
* @memberof google.longrunning
* @see [google.longrunning.DeleteOperationRequest definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/longrunning/operations.proto}
*/
var DeleteOperationRequest = {
const DeleteOperationRequest = {
// This is for documentation. Actual contents will be loaded by gRPC.
};
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,6 @@
* @memberof google.protobuf
* @see [google.protobuf.Any definition in proto format]{@link https://github.com/google/protobuf/blob/master/src/google/protobuf/any.proto}
*/
var Any = {
const Any = {
// This is for documentation. Actual contents will be loaded by gRPC.
};
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,6 @@
* @memberof google.protobuf
* @see [google.protobuf.Duration definition in proto format]{@link https://github.com/google/protobuf/blob/master/src/google/protobuf/duration.proto}
*/
var Duration = {
const Duration = {
// This is for documentation. Actual contents will be loaded by gRPC.
};
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,6 @@
* @memberof google.rpc
* @see [google.rpc.Status definition in proto format]{@link https://github.com/googleapis/googleapis/blob/master/google/rpc/status.proto}
*/
var Status = {
const Status = {
// This is for documentation. Actual contents will be loaded by gRPC.
};
Loading

0 comments on commit 8028bf3

Please sign in to comment.