making some more clear tasking

This commit is contained in:
Chris Cochrun 2024-12-13 23:49:37 -06:00
parent 6c6a7fca15
commit 96419003a7

View file

@ -173,7 +173,6 @@ impl Presenter {
let audio = PathBuf::from(audio);
debug!("{:?}", audio);
if audio.exists() {
debug!("audio exists");
match &self.audio {
Some(aud) if aud != &audio => {
self.audio = Some(audio.clone());
@ -191,7 +190,7 @@ impl Presenter {
};
} else {
self.audio = None;
let _ = self.update(Message::EndAudio);
tasks.push(self.update(Message::EndAudio));
}
}
Task::batch(tasks)