diff --git a/templates/typescript_gapic/src/$version/$service_client.ts.njk b/templates/typescript_gapic/src/$version/$service_client.ts.njk index 8a60b0d2f..9972ce3cf 100644 --- a/templates/typescript_gapic/src/$version/$service_client.ts.njk +++ b/templates/typescript_gapic/src/$version/$service_client.ts.njk @@ -3,7 +3,7 @@ import * as gax from 'google-gax'; import * as path from 'path'; import * as packageJson from '../../package.json'; -import * as protos from '../../pbjs-genfiles/protos'; +import * as protos from '../../protos/protos'; import * as gapicConfig from './echo_client_config.json'; const version = packageJson.version; @@ -181,7 +181,8 @@ export class {{ service.name }}Client { opts.fallback ? // @ts-ignore gaxProtos.lookupService('{{api.naming.protoPackage}}.{{ service.name }}') : - protos.{{api.naming.protoPackage}}.{{ service.name }}, + // @ts-ignore + gaxProtos.{{api.naming.protoPackage}}.{{ service.name }}, opts); const {{ service.name.toCamelCase() }}StubMethods = @@ -356,42 +357,4 @@ export class {{ service.name }}Client { } {%- endif %} {% endfor %} -{% for method in service.longRunning %} - {{ method.name.toCamelCase() }}( - request: protos{{ method.inputInterface }}, - options?: gax.CallOptions): - Promise<[ - protos{{ method.outputInterface }}, - protos{{ method.inputInterface }}|undefined, {}|undefined - ]>; - {{ method.name.toCamelCase() }}( - request: protos{{ method.inputInterface }}, - options: gax.CallOptions, - callback: Callback< - protos{{ method.outputInterface }}, - protos{{ method.inputInterface }}|undefined, - {}|undefined>): void; - {{ method.name.toCamelCase() }}( - request: protos{{ method.inputInterface }}, - optionsOrCallback?: gax.CallOptions|Callback< - protos{{ method.outputInterface }}, - protos{{ method.inputInterface }}|undefined, {}|undefined>, - callback?: Callback< - protos{{ method.outputInterface }}, - protos{{ method.inputInterface }}|undefined, - {}|undefined>): - Promise<[ - protos{{ method.outputInterface }}, - protos{{ method.inputInterface }}|undefined, {}|undefined - ]>|void { - request = request || {}; - let options = optionsOrCallback; - if (typeof options === 'function' && callback === undefined) { - callback = options; - options = {}; - } - options = options || {}; - return this._innerApiCalls.{{ method.name.toCamelCase() }}(request, options, callback); - } -{% endfor %} }