Handle library updates from main screen

This commit is contained in:
Elias Projahn 2021-04-25 12:27:04 +02:00
parent cb3e958f1b
commit 24f493d7d6

View file

@ -153,6 +153,9 @@ impl Screen<(), ()> for MainScreen {
// Load the content asynchronously.
spawn!(@clone this, async move {
loop {
this.navigator.reset();
let mut poes = Vec::new();
let persons = this.handle.backend.db().get_persons().await.unwrap();
@ -171,6 +174,11 @@ impl Screen<(), ()> for MainScreen {
this.poe_list.update(length);
this.stack.set_visible_child_name("content");
if this.handle.backend.library_update().await.is_err() {
break;
}
}
});
this