Skip to content

Commit 2a54a6e

Browse files
Use the new cached method fromJSON from google-gax
1 parent 1acf5f4 commit 2a54a6e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

templates/cjs/typescript_gapic/src/$version/$service_client.ts.njk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ export class {{ service.name }}Client {
322322
protoFilesRoot) as (typeof protoFilesRoot);
323323
{%- else %}
324324

325-
const protoFilesRoot = this._gaxModule.protobuf.Root.fromJSON(jsonProtos);
325+
const protoFilesRoot = this._gaxModule.protobufFromJSON(jsonProtos);
326326
{%- endif %}
327327
{%- endif %}
328328
{%- if service.longRunning.length > 0 or service.LongRunningOperationsMixin > 0%}

templates/esm/typescript_gapic/esm/src/$version/$service_client.ts.njk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,7 @@ export class {{ service.name }}Client {
332332
protoFilesRoot) as (typeof protoFilesRoot);
333333
{%- else %}
334334

335-
const protoFilesRoot = this._gaxModule.protobuf.Root.fromJSON(jsonProtos as gax.protobuf.INamespace);
335+
const protoFilesRoot = this._gaxModule.protobufFromJSON(jsonProtos);
336336
{%- endif %}
337337
{%- endif %}
338338
{%- if service.longRunning.length > 0 or service.LongRunningOperationsMixin > 0%}

0 commit comments

Comments
 (0)