wait for account data population and set initial AccountBloc status
This commit is contained in:
@@ -4,7 +4,7 @@ import 'account_event.dart';
|
||||
import 'account_state.dart';
|
||||
|
||||
class AccountBloc extends Bloc<AccountEvent, AccountState> {
|
||||
AccountBloc() : super(const AccountState()) {
|
||||
AccountBloc({AccountStatus initialStatus = AccountStatus.undefined}) : super(AccountState(status: initialStatus)) {
|
||||
on<AccountStatusChanged>((event, emit) => emit(state.copyWith(status: event.status)));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user