Don't panic if check_task runs into an error
This commit is contained in:
@@ -114,8 +114,11 @@ async fn main() {
|
|||||||
|
|
||||||
sleep(sleep_duration).await;
|
sleep(sleep_duration).await;
|
||||||
|
|
||||||
// TODO Log the error and continue instead
|
let result = check_task(&bot, config.reminder_time, &db).await;
|
||||||
check_task(&bot, config.reminder_time, &db).await.unwrap();
|
if let Err(e) = result {
|
||||||
|
// TODO Emitting a backtrace would be nice
|
||||||
|
error!("{}", e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user