Add context to iteration errors
This commit is contained in:
@@ -257,7 +257,8 @@ impl QueueManagement for Server {
|
||||
Ok(max_total == 0 || total < max_total)
|
||||
},
|
||||
)
|
||||
.await?;
|
||||
.await
|
||||
.caused_by(trc::location!())?;
|
||||
|
||||
Ok(if values {
|
||||
JsonResponse::new(json!({
|
||||
@@ -512,7 +513,8 @@ impl QueueManagement for Server {
|
||||
Ok(max_total == 0 || total < max_total)
|
||||
},
|
||||
)
|
||||
.await?;
|
||||
.await
|
||||
.caused_by(trc::location!())?;
|
||||
|
||||
Ok(JsonResponse::new(json!({
|
||||
"data": {
|
||||
|
||||
@@ -227,7 +227,7 @@ impl ManageReports for Server {
|
||||
Ok(max_total == 0 || total < max_total)
|
||||
},
|
||||
)
|
||||
.await?;
|
||||
.await.caused_by(trc::location!())?;
|
||||
|
||||
Ok(JsonResponse::new(json!({
|
||||
"data": {
|
||||
|
||||
@@ -118,7 +118,7 @@ impl Indexer for Server {
|
||||
)
|
||||
.await
|
||||
.map_err(|err| {
|
||||
trc::error!(err.details("Failed to iterate over index emails"));
|
||||
trc::error!(err.caused_by(trc::location!()).details("Failed to iterate over index emails"));
|
||||
});
|
||||
|
||||
// Add entries to the index
|
||||
|
||||
Reference in New Issue
Block a user