fix import for derived accounts and hopefully make other account-access code more robust

This commit is contained in:
2025-06-08 19:14:41 -06:00
parent f79568cc5d
commit 26951cc472
6 changed files with 70 additions and 107 deletions

View File

@@ -167,6 +167,7 @@ import {
} from "../libs/endorserServer";
import { logger } from "../utils/logger";
import { PlatformServiceFactory } from "@/services/PlatformServiceFactory";
import { retrieveAllAccountsMetadata } from "@/libs/util";
@Component({
methods: { claimSpecialDescription },
components: {
@@ -229,13 +230,7 @@ export default class QuickActionBvcBeginView extends Vue {
suppressMilliseconds: true,
}) || "";
const queryResult = await platformService.dbQuery(
"SELECT did FROM accounts",
);
this.allMyDids =
databaseUtil
.mapQueryResultToValues(queryResult)
?.map((row) => row[0] as string) || [];
this.allMyDids = (await retrieveAllAccountsMetadata()).map((account) => account.did);
if (USE_DEXIE_DB) {
const accountsDB = await accountsDBPromise;
await accountsDB.open();