mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2025-08-02 19:26:16 -04:00
refactor
This commit is contained in:
parent
2ccad50f9a
commit
360ba436f8
29 changed files with 501 additions and 317 deletions
|
@ -31,7 +31,7 @@ class ValidContactInvitation {
|
|||
final pool = DHTRecordPool.instance;
|
||||
try {
|
||||
final unlockedAccountInfo =
|
||||
_locator<ActiveAccountInfoCubit>().state.unlockedAccountInfo!;
|
||||
_locator<AccountInfoCubit>().state.unlockedAccountInfo!;
|
||||
final accountRecordKey = unlockedAccountInfo.accountRecordKey;
|
||||
final identityPublicKey = unlockedAccountInfo.identityPublicKey;
|
||||
|
||||
|
@ -43,7 +43,8 @@ class ValidContactInvitation {
|
|||
return (await pool.openRecordWrite(_contactRequestInboxKey, _writer,
|
||||
debugName: 'ValidContactInvitation::accept::'
|
||||
'ContactRequestInbox',
|
||||
parent: accountRecordKey))
|
||||
parent: pool.getParentRecordKey(_contactRequestInboxKey) ??
|
||||
accountRecordKey))
|
||||
// ignore: prefer_expression_function_bodies
|
||||
.maybeDeleteScope(!isSelf, (contactRequestInbox) async {
|
||||
// Create local conversation key for this
|
||||
|
@ -96,7 +97,7 @@ class ValidContactInvitation {
|
|||
final pool = DHTRecordPool.instance;
|
||||
|
||||
final unlockedAccountInfo =
|
||||
_locator<ActiveAccountInfoCubit>().state.unlockedAccountInfo!;
|
||||
_locator<AccountInfoCubit>().state.unlockedAccountInfo!;
|
||||
final accountRecordKey = unlockedAccountInfo.accountRecordKey;
|
||||
final identityPublicKey = unlockedAccountInfo.identityPublicKey;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue