diff --git a/src/grpc.server.ts b/src/grpc.server.ts index cdeac4a..7f5b26e 100644 --- a/src/grpc.server.ts +++ b/src/grpc.server.ts @@ -100,7 +100,8 @@ export class GrpcServer extends Context implements Server { // tslint:disable-next-line:no-any const serviceMeta = pkgMeta[config.SERVICE_NAME] as any; // tslint:disable-next-line:no-any - const serviceDef: grpc.ServiceDefinition = serviceMeta.service; + const serviceDef: grpc.ServiceDefinition = + { [methodName]: serviceMeta.service[methodName] }; this.server.addService(serviceDef, { [config.METHOD_NAME]: this.setupGrpcCall(ctor, methodName, config), });