Apply cargo fmt
This commit is contained in:
parent
7af58de9fa
commit
9fef178a27
16
src/error.rs
16
src/error.rs
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user