mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2025-05-07 16:54:58 -04:00
invitation work
This commit is contained in:
parent
95ed8b28a0
commit
7496a1a2a7
22 changed files with 591 additions and 47 deletions
|
@ -131,15 +131,22 @@ extension IdentityMasterExtension on IdentityMaster {
|
|||
// Create new account to insert into identity
|
||||
await (await pool.create(parent: identityRec.key))
|
||||
.deleteScope((accountRec) async {
|
||||
// Make empty contact list
|
||||
final contactList =
|
||||
await (await DHTShortArray.create(parent: accountRec.key))
|
||||
.scope((r) => r.record.ownedDHTRecordPointer);
|
||||
|
||||
// Make empty contact invitation record list
|
||||
final contactInvitationRecords = await (await DHTShortArray.create())
|
||||
.scope((r) => r.record.ownedDHTRecordPointer);
|
||||
final contactInvitationRecords =
|
||||
await (await DHTShortArray.create(parent: accountRec.key))
|
||||
.scope((r) => r.record.ownedDHTRecordPointer);
|
||||
|
||||
// Make account object
|
||||
final account = proto.Account()
|
||||
..profile = (proto.Profile()
|
||||
..name = name
|
||||
..title = title)
|
||||
..contactList = contactList.toProto()
|
||||
..contactInvitationRecords = contactInvitationRecords.toProto();
|
||||
|
||||
// Write account key
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue