From 24629931388042ddb9c54cb2b3542d5a5e2173cc Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Mon, 16 Oct 2023 14:53:37 +0530 Subject: [PATCH] fix: fix: merge issues (#786) --- packages/restapi/src/lib/pushapi/PushAPI.ts | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index 162d40a85..429b3aac3 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -73,10 +73,7 @@ export class PushAPI { static async initialize( signer: SignerType, - options?: PushAPIInitializeProps, - version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3, - versionMeta?: { NFTPGP_V1?: { password: string } }, - autoUpgrade?: boolean + options?: PushAPIInitializeProps ): Promise { try { // Default options @@ -97,10 +94,12 @@ export class PushAPI { const settings = { ...defaultOptions, ...options, - version: version || defaultOptions.version, - versionMeta: versionMeta || defaultOptions.versionMeta, + version: options?.version || defaultOptions.version, + versionMeta: options?.versionMeta || defaultOptions.versionMeta, autoUpgrade: - autoUpgrade !== undefined ? autoUpgrade : defaultOptions.autoUpgrade, + options?.autoUpgrade !== undefined + ? options?.autoUpgrade + : defaultOptions.autoUpgrade, streamOptions: { ...defaultOptions.streamOptions, ...(options?.streamOptions ?? {}),