Skip to content

Commit

Permalink
grpc-loader: add method options in MethodDefinition
Browse files Browse the repository at this point in the history
  • Loading branch information
hiepthai authored and n0v1 committed Apr 5, 2024
1 parent be40682 commit c7d4566
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/proto-loader/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,8 @@ export interface MethodDefinition<RequestType, ResponseType, OutputRequestType=R
originalName?: string;
requestType: MessageTypeDefinition;
responseType: MessageTypeDefinition;
options?: Protobuf.IMethod['options'];
parsedOptions?: Protobuf.IMethod['parsedOptions'];
}

export interface ServiceDefinition {
Expand Down Expand Up @@ -242,6 +244,8 @@ function createMethodDefinition(
originalName: camelCase(method.name),
requestType: createMessageDefinition(requestType, fileDescriptors),
responseType: createMessageDefinition(responseType, fileDescriptors),
options: method.options,
parsedOptions: method.parsedOptions,
};
}

Expand Down

0 comments on commit c7d4566

Please sign in to comment.