making some more clear tasking
This commit is contained in:
parent
6c6a7fca15
commit
96419003a7
|
@ -173,7 +173,6 @@ impl Presenter {
|
||||||
let audio = PathBuf::from(audio);
|
let audio = PathBuf::from(audio);
|
||||||
debug!("{:?}", audio);
|
debug!("{:?}", audio);
|
||||||
if audio.exists() {
|
if audio.exists() {
|
||||||
debug!("audio exists");
|
|
||||||
match &self.audio {
|
match &self.audio {
|
||||||
Some(aud) if aud != &audio => {
|
Some(aud) if aud != &audio => {
|
||||||
self.audio = Some(audio.clone());
|
self.audio = Some(audio.clone());
|
||||||
|
@ -191,7 +190,7 @@ impl Presenter {
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
self.audio = None;
|
self.audio = None;
|
||||||
let _ = self.update(Message::EndAudio);
|
tasks.push(self.update(Message::EndAudio));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Task::batch(tasks)
|
Task::batch(tasks)
|
||||||
|
|
Loading…
Reference in a new issue