Browse Source

neon: Fix user details and user status bloc caching

pull/104/head
jld3103 2 years ago
parent
commit
3f3645b8e4
No known key found for this signature in database
GPG Key ID: 9062417B9E8EB7B3
  1. 8
      packages/neon/lib/src/blocs/accounts.dart

8
packages/neon/lib/src/blocs/accounts.dart

@ -139,8 +139,8 @@ class AccountsBloc extends $AccountsBloc {
}
UserDetailsBloc getUserDetailsBloc(final Account account) {
if (_userDetailsBlocs[account] != null) {
return _userDetailsBlocs[account]!;
if (_userDetailsBlocs[account.id] != null) {
return _userDetailsBlocs[account.id]!;
}
return _userDetailsBlocs[account.id] = UserDetailsBloc(
@ -150,8 +150,8 @@ class AccountsBloc extends $AccountsBloc {
}
UserStatusBloc getUserStatusBloc(final Account account) {
if (_userStatusBlocs[account] != null) {
return _userStatusBlocs[account]!;
if (_userStatusBlocs[account.id] != null) {
return _userStatusBlocs[account.id]!;
}
return _userStatusBlocs[account.id] = UserStatusBloc(

Loading…
Cancel
Save