Add getAllDiffs and getDiffbyValue
This commit is contained in:
parent
48cd8e3757
commit
06358670c2
@ -160,6 +160,18 @@ export default class Services {
|
||||
return secretsStore;
|
||||
}
|
||||
|
||||
public async getAllDiffs(): Promise<Record<string, UserDiff>> {
|
||||
const db = await Database.getInstance();
|
||||
return await db.dumpStore('diffs');
|
||||
}
|
||||
|
||||
public async getDiffByValue(value: string): Promise<UserDiff | null> {
|
||||
const db = await Database.getInstance();
|
||||
const store = 'diffs';
|
||||
const res = await db.getObject(store, value);
|
||||
return res;
|
||||
}
|
||||
|
||||
public async checkConnections(members: Member[]): Promise<void> {
|
||||
const memberPromises = members.map(async (member) => {
|
||||
const addressPromises = member.sp_addresses.map(async (address) => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user