Skip to content

Commit a6e2178

Browse files
committed
fix: the fix for fmtting ci
1 parent 45bfadb commit a6e2178

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

justfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ t:
22
cargo t
33

44
fmt:
5-
rustfmt +nightly **/*.rs
5+
cargo +nightly fmt --all
66

77
clippy:
88
cargo clippy --all-features -- -D warnings

utils/html-solver/src/main.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1+
use std::{convert::Infallible, fs, net::SocketAddr, path::Path};
2+
13
use hyper::{
24
service::{make_service_fn, service_fn},
35
Body, Request, Response, Server, StatusCode,
46
};
5-
use std::{convert::Infallible, fs, net::SocketAddr, path::Path};
67

78
async fn serve_file(req: Request<Body>) -> Result<Response<Body>, Infallible> {
89
let path = match req.uri().path() {
@@ -36,9 +37,7 @@ async fn serve_file(req: Request<Body>) -> Result<Response<Body>, Infallible> {
3637
async fn main() {
3738
let addr = SocketAddr::from(([127, 0, 0, 1], 3001));
3839

39-
let make_svc = make_service_fn(|_conn| {
40-
async { Ok::<_, Infallible>(service_fn(serve_file)) }
41-
});
40+
let make_svc = make_service_fn(|_conn| async { Ok::<_, Infallible>(service_fn(serve_file)) });
4241

4342
let server = Server::bind(&addr).serve(make_svc);
4443

0 commit comments

Comments
 (0)