Fixing closures.

This commit is contained in:
Dessalines 2020-04-21 16:48:54 -04:00
parent 01b7ac5fb9
commit 809cc1049e
4 changed files with 5 additions and 5 deletions

View file

@ -158,7 +158,7 @@ where
let res = web::block(move || oper.perform(db.get_ref().to_owned(), Some(ws_info)))
.await
.map(|json| HttpResponse::Ok().json(json))
.map_err(|e| ErrorBadRequest(e))?;
.map_err(ErrorBadRequest)?;
Ok(res)
}

View file

@ -39,7 +39,7 @@ async fn get_all_feed(
.content_type("application/rss+xml")
.body(rss)
})
.map_err(|e| ErrorBadRequest(e))?;
.map_err(ErrorBadRequest)?;
Ok(res)
}
@ -100,7 +100,7 @@ async fn get_feed(
.content_type("application/rss+xml")
.body(rss)
})
.map_err(|e| ErrorBadRequest(e))?;
.map_err(ErrorBadRequest)?;
Ok(res)
}

View file

@ -49,7 +49,7 @@ async fn node_info(
})
.await
.map(|json| HttpResponse::Ok().json(json))
.map_err(|e| ErrorBadRequest(e))?;
.map_err(ErrorBadRequest)?;
Ok(res)
}

View file

@ -84,6 +84,6 @@ async fn get_webfinger_response(
})
.await
.map(|json| HttpResponse::Ok().json(json))
.map_err(|e| ErrorBadRequest(e))?;
.map_err(ErrorBadRequest)?;
Ok(res)
}