Add a function to get a pairingProcess from an spAddress

This commit is contained in:
NicolasCantu 2025-01-23 19:51:02 +01:00
parent 5c05f2119d
commit 68c6383502

View File

@ -660,6 +660,20 @@ class ChatElement extends HTMLElement {
return this.addressMap;
}
//To get a pairing process from an sp adsress
async getPairingProcess(spAddress: string){
const addressMap = await this.getAddressMap();
for [key, value] of Object.entries(addressMap){
if (key == spAddress) {
const pairingProcess = value;
}
}
return this.pairingProcess;
}
private async toggleMembers(roleData: any, roleElement: HTMLElement) {
let memberList = roleElement.querySelector('.member-list');
const roleName = roleElement.querySelector('.role-name')?.textContent || '';