add dc_accounts_maybe_network_lost() (#2550)

This commit is contained in:
bjoern
2021-07-22 11:29:51 +02:00
committed by GitHub
parent 5f365b259b
commit 980d2a9433
4 changed files with 53 additions and 1 deletions

View File

@@ -219,6 +219,13 @@ impl Accounts {
}
}
pub async fn maybe_network_lost(&self) {
let accounts = &*self.accounts.read().await;
for account in accounts.values() {
account.maybe_network_lost().await;
}
}
/// Unified event emitter.
pub async fn get_event_emitter(&self) -> EventEmitter {
let emitters: Vec<_> = self