diff --git a/ios/Wrappers/AuthParamsWrapper.swift b/ios/Wrappers/AuthParamsWrapper.swift index 0c4fbe47..8ea33ea7 100644 --- a/ios/Wrappers/AuthParamsWrapper.swift +++ b/ios/Wrappers/AuthParamsWrapper.swift @@ -52,7 +52,7 @@ struct AuthParamsWrapper { dbDirectory: dbDirectory, historySyncUrl: historySyncUrl, isSmartContractWallet: isSmartContractWallet, - chainId: blockNumber != nil ? UInt64(chainId!) : nil, + chainId: chainId != nil ? UInt64(chainId!) : nil, blockNumber: blockNumber != nil ? UInt64(blockNumber!) : nil ) } diff --git a/src/index.ts b/src/index.ts index 9715410b..167f8523 100644 --- a/src/index.ts +++ b/src/index.ts @@ -255,8 +255,8 @@ export async function createV3( export async function buildV3( address: string, - chainId?: number | undefined, environment: 'local' | 'dev' | 'production', + chainId?: number | undefined, appVersion?: string | undefined, enableV3?: boolean | undefined, dbEncryptionKey?: Uint8Array | undefined, diff --git a/src/lib/Client.ts b/src/lib/Client.ts index ca4dd7c3..f009d346 100644 --- a/src/lib/Client.ts +++ b/src/lib/Client.ts @@ -334,7 +334,7 @@ export class Client< if (signer.isSmartContractWallet()) { await XMTPModule.receiveSCWSignature( request.id, - Buffer.from(signatureString) + signatureString ) } else { const eSig = splitSignature(signatureString) @@ -438,8 +438,8 @@ export class Client< } const client = await XMTPModule.buildV3( address, - chainId, options.env, + chainId, options.appVersion, Boolean(options.enableV3), options.dbEncryptionKey,