diff --git a/app/core/SDKConnect/SDKDeeplinkProtocol/DeeplinkProtocolService.ts b/app/core/SDKConnect/SDKDeeplinkProtocol/DeeplinkProtocolService.ts index 60595123ccf..5ca07e0bf1d 100644 --- a/app/core/SDKConnect/SDKDeeplinkProtocol/DeeplinkProtocolService.ts +++ b/app/core/SDKConnect/SDKDeeplinkProtocol/DeeplinkProtocolService.ts @@ -301,31 +301,30 @@ export default class DeeplinkProtocolService { `DeeplinkProtocolService::clients_connected - new client ${clientInfo.clientId}}`, this.connections, ); - // Ask for account permissions + await this.checkPermission({ - originatorInfo: clientInfo.originatorInfo, channelId: clientInfo.clientId, + originatorInfo: clientInfo.originatorInfo, }); this.setupBridge(clientInfo); - // Save session to SDKConnect - // Save to local connections + this.connections[clientInfo.clientId] = { - connected: true, clientId: clientInfo.clientId, - originatorInfo: clientInfo.originatorInfo, + connected: true, validUntil: clientInfo.validUntil, scheme: clientInfo.scheme, + originatorInfo: clientInfo.originatorInfo, }; await SDKConnect.getInstance().addDappConnection({ id: clientInfo.clientId, - lastAuthorized: Date.now(), origin: AppConstants.MM_SDK.IOS_SDK, - originatorInfo: clientInfo.originatorInfo, + lastAuthorized: Date.now(), otherPublicKey: this.dappPublicKeyByClientId[clientInfo.clientId], - validUntil: Date.now() + DEFAULT_SESSION_TIMEOUT_MS, + originatorInfo: clientInfo.originatorInfo, scheme: clientInfo.scheme, + validUntil: Date.now() + DEFAULT_SESSION_TIMEOUT_MS, }); }