Apply cargo fmt

This commit is contained in:
Valentin Brandl 2020-03-21 13:02:53 +01:00
parent 7af58de9fa
commit 9fef178a27
No known key found for this signature in database
GPG Key ID: 30D341DD34118D7D

View File

@ -43,13 +43,17 @@ impl ResponseError for Error {
let mut buf = Vec::new();
match self {
Error::GitNoMaster => {
templates::p404_no_master(&mut buf, VERSION_INFO, REPO_COUNT.load(Ordering::Relaxed)).unwrap();
HttpResponse::NotFound()
.content_type("text/html")
.body(buf)
},
templates::p404_no_master(
&mut buf,
VERSION_INFO,
REPO_COUNT.load(Ordering::Relaxed),
)
.unwrap();
HttpResponse::NotFound().content_type("text/html").body(buf)
}
_ => {
templates::p500(&mut buf, VERSION_INFO, REPO_COUNT.load(Ordering::Relaxed)).unwrap();
templates::p500(&mut buf, VERSION_INFO, REPO_COUNT.load(Ordering::Relaxed))
.unwrap();
HttpResponse::InternalServerError()
.content_type("text/html")
.body(buf)