diff options
-rw-r--r-- | src/node/interop/interop_client.js | 4 | ||||
-rw-r--r-- | src/node/src/client.js | 16 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/node/interop/interop_client.js b/src/node/interop/interop_client.js index 9100edf243..2f8eaea41d 100644 --- a/src/node/interop/interop_client.js +++ b/src/node/interop/interop_client.js @@ -285,7 +285,7 @@ function authTest(expected_user, scope, client, done) { if (credential.createScopedRequired() && scope) { credential = credential.createScoped(scope); } - client.$updateMetadata = grpc.getGoogleAuthDelegate(credential); + client.$_updateMetadata = grpc.getGoogleAuthDelegate(credential); var arg = { response_type: 'COMPRESSABLE', response_size: 314159, @@ -344,7 +344,7 @@ function oauth2Test(expected_user, scope, per_rpc, client, done) { if (per_rpc) { updateMetadata('', {}, makeTestCall); } else { - client.$updateMetadata = updateMetadata; + client.$_updateMetadata = updateMetadata; makeTestCall(null, {}); } }); diff --git a/src/node/src/client.js b/src/node/src/client.js index f288104e2b..ddd28e37b8 100644 --- a/src/node/src/client.js +++ b/src/node/src/client.js @@ -32,7 +32,7 @@ */ /** - * Server module + * Client module * @module */ @@ -272,7 +272,7 @@ function makeUnaryRequestFunction(method, serialize, deserialize) { emitter.getPeer = function getPeer() { return call.getPeer(); }; - this.$updateMetadata(this.$auth_uri, metadata, function(error, metadata) { + this.$_updateMetadata(this.$_auth_uri, metadata, function(error, metadata) { if (error) { call.cancel(); callback(error); @@ -340,7 +340,7 @@ function makeClientStreamRequestFunction(method, serialize, deserialize) { metadata = {}; } var stream = new ClientWritableStream(call, serialize); - this.$updateMetadata(this.$auth_uri, metadata, function(error, metadata) { + this.$_updateMetadata(this.$_auth_uri, metadata, function(error, metadata) { if (error) { call.cancel(); callback(error); @@ -410,7 +410,7 @@ function makeServerStreamRequestFunction(method, serialize, deserialize) { metadata = {}; } var stream = new ClientReadableStream(call, deserialize); - this.$updateMetadata(this.$auth_uri, metadata, function(error, metadata) { + this.$_updateMetadata(this.$_auth_uri, metadata, function(error, metadata) { if (error) { call.cancel(); stream.emit('error', error); @@ -482,7 +482,7 @@ function makeBidiStreamRequestFunction(method, serialize, deserialize) { metadata = {}; } var stream = new ClientDuplexStream(call, serialize, deserialize); - this.$updateMetadata(this.$auth_uri, metadata, function(error, metadata) { + this.$_updateMetadata(this.$_auth_uri, metadata, function(error, metadata) { if (error) { call.cancel(); stream.emit('error', error); @@ -572,9 +572,9 @@ exports.makeClientConstructor = function(methods, serviceName) { this.$channel = new grpc.Channel(address, credentials, options); // Remove the optional DNS scheme, trailing port, and trailing backslash address = address.replace(/^(dns:\/{3})?([^:\/]+)(:\d+)?\/?$/, '$2'); - this.$server_address = address; - this.$auth_uri = 'https://' + this.server_address + '/' + serviceName; - this.$updateMetadata = updateMetadata; + this.$_server_address = address; + this.$_auth_uri = 'https://' + this.server_address + '/' + serviceName; + this.$_updateMetadata = updateMetadata; } /** |