Parse incoming data from meta into JSON format.

This commit is contained in:
Spencer Ofwiti 2021-05-18 19:06:57 +03:00
parent 7b83dbecd3
commit 7a2321f444

View File

@ -200,7 +200,7 @@ export class UserService {
.pipe(first()) .pipe(first())
.subscribe(async (res) => { .subscribe(async (res) => {
const account: Syncable = Envelope.fromJSON(JSON.stringify(res)).unwrap(); const account: Syncable = Envelope.fromJSON(JSON.stringify(res)).unwrap();
const accountInfo = account.m.data; const accountInfo = JSON.parse(account.m.data);
await personValidation(accountInfo); await personValidation(accountInfo);
this.tokenService.onload = async (status: boolean): Promise<void> => { this.tokenService.onload = async (status: boolean): Promise<void> => {
accountInfo.balance = await this.tokenService.getTokenBalance( accountInfo.balance = await this.tokenService.getTokenBalance(