@@ -134,7 +134,7 @@ Next, we need to implement the service. To define a handler that fulfills this d
134134@Controller ()
135135export class HeroesController {
136136 @GrpcMethod (' HeroesService' , ' FindOne' )
137- findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any >): Hero {
137+ findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any , any >): Hero {
138138 const items = [
139139 { id: 1 , name: ' John' },
140140 { id: 2 , name: ' Doe' },
@@ -170,7 +170,7 @@ Both `@GrpcMethod()` decorator arguments are optional. If called without the sec
170170@Controller ()
171171export class HeroesController {
172172 @GrpcMethod (' HeroesService' )
173- findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any >): Hero {
173+ findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any , any >): Hero {
174174 const items = [
175175 { id: 1 , name: ' John' },
176176 { id: 2 , name: ' Doe' },
@@ -199,7 +199,7 @@ You can also omit the first `@GrpcMethod()` argument. In this case, Nest automat
199199@Controller ()
200200export class HeroesService {
201201 @GrpcMethod ()
202- findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any >): Hero {
202+ findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any , any >): Hero {
203203 const items = [
204204 { id: 1 , name: ' John' },
205205 { id: 2 , name: ' Doe' },
@@ -493,7 +493,7 @@ To send back metadata from the handler, use the `ServerUnaryCall#sendMetadata()`
493493@Controller ()
494494export class HeroesService {
495495 @GrpcMethod ()
496- findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any >): Hero {
496+ findOne(data : HeroById , metadata : Metadata , call : ServerUnaryCall <any , any >): Hero {
497497 const serverMetadata = new Metadata ();
498498 const items = [
499499 { id: 1 , name: ' John' },
0 commit comments