Rm uneccessary async on getDeviceAddress()

This commit is contained in:
Sosthene 2025-07-07 15:20:00 +02:00
parent 189bd3d252
commit 39f24114e1

View File

@ -201,7 +201,7 @@ export default class Services {
// Ensure the amount is available before proceeding
await this.getTokensFromFaucet();
let unconnectedAddresses = [];
const myAddress = await this.getDeviceAddress();
const myAddress = this.getDeviceAddress();
for (const member of members) {
const sp_addresses = member.sp_addresses;
if (!sp_addresses || sp_addresses.length === 0) continue;
@ -693,8 +693,12 @@ export default class Services {
return amount;
}
async getDeviceAddress() {
return await this.sdkClient.get_address();
getDeviceAddress(): string {
try {
return this.sdkClient.get_address();
} catch (e) {
throw new Error(`Failed to get device address: ${e}`);
}
}
public dumpDeviceFromMemory(): string {