improve panic message

This commit is contained in:
tamo 2021-05-25 15:47:57 +02:00
parent e5175f5dc1
commit 89846d1656
No known key found for this signature in database
GPG Key ID: 20CD8020AFA88D69

View File

@ -114,11 +114,11 @@ where
match task_result {
Ok(Ok(())) => {
(*dump_info.write().await).as_mut().expect("Dump actor should have an inbox").done();
(*dump_info.write().await).as_mut().expect("Inconsistent dump service state").done();
info!("Dump succeed");
}
Ok(Err(e)) => {
(*dump_info.write().await).as_mut().expect("Dump actor should have an inbox").with_error(e.to_string());
(*dump_info.write().await).as_mut().expect("Inconsistent dump service state").with_error(e.to_string());
error!("Dump failed: {}", e);
}
Err(_) => {