From 6b37fa635991aa58e6a0bb55b561f3d0122a9ce4 Mon Sep 17 00:00:00 2001 From: "Chakhsu.Lau" Date: Wed, 17 Jan 2024 18:25:52 +0800 Subject: [PATCH] fix: allow makeMetadata with no params --- src/loader.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/loader.ts b/src/loader.ts index 8b6e45e..0cefdcc 100644 --- a/src/loader.ts +++ b/src/loader.ts @@ -106,7 +106,7 @@ export class ProtoLoader { } } - makeMetadata(initialValues: Record) { + makeMetadata(initialValues?: Record) { const meta = new grpc.Metadata() if (typeof initialValues === 'object') { Object.entries(initialValues).forEach(([key, value]: [string, any]) => {