mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2025-05-02 14:26:12 -04:00
more refactor
This commit is contained in:
parent
0291ff7224
commit
b35b618a4d
10 changed files with 162 additions and 152 deletions
|
@ -7,7 +7,6 @@ import 'package:flutter_translate/flutter_translate.dart';
|
|||
import 'package:go_router/go_router.dart';
|
||||
import 'package:veilid_support/veilid_support.dart';
|
||||
|
||||
import '../../proto/proto.dart' as proto;
|
||||
import '../account_manager/account_manager.dart';
|
||||
import '../chat/chat.dart';
|
||||
import '../theme/theme.dart';
|
||||
|
@ -115,7 +114,7 @@ class HomePageState extends State<HomePage> with TickerProviderStateMixin {
|
|||
}
|
||||
|
||||
final account = AccountRepository.instance
|
||||
.getAccountInfo(accountMasterRecordKey: activeUserLogin);
|
||||
.getAccountInfo(accountMasterRecordKey: activeUserLogin)!;
|
||||
|
||||
switch (account.status) {
|
||||
case AccountInfoStatus.noAccount:
|
||||
|
@ -152,7 +151,7 @@ class HomePageState extends State<HomePage> with TickerProviderStateMixin {
|
|||
context,
|
||||
localAccounts,
|
||||
activeUserLogin,
|
||||
account.accountRecord!,
|
||||
account.activeAccountInfo!.accountRecord,
|
||||
);
|
||||
}
|
||||
});
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
// ignore_for_file: prefer_const_constructors
|
||||
|
||||
import 'package:awesome_extensions/awesome_extensions.dart';
|
||||
import 'package:fast_immutable_collections/fast_immutable_collections.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
|
@ -58,6 +56,8 @@ class AccountPageState extends State<AccountPage> {
|
|||
final textTheme = theme.textTheme;
|
||||
final scale = theme.extension<ScaleScheme>()!;
|
||||
|
||||
final records = widget.account.contactInvitationRecords;
|
||||
|
||||
final contactInvitationRecordList =
|
||||
ref.watch(fetchContactInvitationRecordsProvider).asData?.value ??
|
||||
const IListConst([]);
|
Loading…
Add table
Add a link
Reference in a new issue