Compare commits

..

No commits in common. "0097a0533a06630f807c27e87b262ed2ee9f0b46" and "b6a17184eb581c67b6c41c6a73efa54ba4c27ad9" have entirely different histories.

View file

@ -1,11 +1,11 @@
pub mod activitypub; pub mod activitypub;
#[cfg(feature = "mastodon")]
pub mod mastodon;
#[cfg(feature = "web")] #[cfg(feature = "web")]
pub mod web; pub mod web;
#[cfg(feature = "mastodon")]
pub mod mastodon;
pub mod builders; pub mod builders;
#[cfg(not(feature = "mastodon"))] #[cfg(not(feature = "mastodon"))]
@ -26,17 +26,7 @@ pub async fn serve(ctx: upub::Context, bind: String) -> upub::Result<()> {
.ap_routes() .ap_routes()
.mastodon_routes() // no-op if mastodon feature is disabled .mastodon_routes() // no-op if mastodon feature is disabled
.layer(CorsLayer::permissive()) .layer(CorsLayer::permissive())
.layer( .layer(TraceLayer::new_for_http())
TraceLayer::new_for_http()
.make_span_with(|req: &axum::http::Request<_>| {
tracing::span!(
tracing::Level::INFO,
"request",
uri = %req.uri(),
status_code = tracing::field::Empty,
)
})
)
.with_state(ctx); .with_state(ctx);
// run our app with hyper, listening locally on port 3000 // run our app with hyper, listening locally on port 3000