HOLY SHIT, MIDDLEWARE ORDER MATTERED

https://issueexplorer.com/issue/actix/actix-extras/191
This commit is contained in:
Brandon Thomas committed 2021-11-12 19:52:00 -05:00
1 parent 38cc8f31a8
commit 6849e6d051
1 file changed
+3 -3
+3 -3
View File
@@ -319,13 +319,13 @@ pub async fn serve(server_state: ServerState) -> AnyhowResult<()>
App::new()
.app_data(server_state_arc.clone())
.wrap(build_common_cors_config())
.wrap(Logger::new(&log_format)
.exclude("/liveness")
.exclude("/readiness"))
.wrap(DefaultHeaders::new()
.header("X-Backend-Hostname", &hostname)
.header("X-Build-Sha", ""))
.wrap(IpFilter::new(ip_banlist))
.wrap(Logger::new(&log_format)
.exclude("/liveness")
.exclude("/readiness"))
// ==================== ACCOUNT CREATION / SESSION MANAGEMENT ====================
.service(
web::resource("/create_account")