Skip to content

Commit

Permalink
Fix up formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
offbyone committed Oct 3, 2023
1 parent 6367caf commit 21810f5
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions atuin-server/src/router.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,9 @@ async fn clacks_overhead<B>(request: Request<B>, next: Next<B>) -> Response {
let gnu_terry_value = "GNU Terry Pratchett";
let gnu_terry_header = "X-Clacks-Overhead";

response.headers_mut().insert(gnu_terry_header, gnu_terry_value.parse().unwrap());
response
.headers_mut()
.insert(gnu_terry_header, gnu_terry_value.parse().unwrap());
response
}

Expand Down Expand Up @@ -119,7 +121,9 @@ pub fn router<DB: Database>(database: DB, settings: Settings<DB::Settings>) -> R
}
.fallback(teapot)
.with_state(AppState { database, settings })
.layer(ServiceBuilder::new()
.layer(axum::middleware::from_fn(clacks_overhead))
.layer(TraceLayer::new_for_http()))
.layer(
ServiceBuilder::new()
.layer(axum::middleware::from_fn(clacks_overhead))
.layer(TraceLayer::new_for_http()),
)
}

0 comments on commit 21810f5

Please sign in to comment.