Skip to content

Commit

Permalink
fixed cors AGAIN
Browse files Browse the repository at this point in the history
  • Loading branch information
Dromader2137 committed Apr 25, 2024
1 parent 6119c7f commit eb32a33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,6 @@ async fn main() {
.allow_headers(vec!["content-type", "Access-Control-Allow-Origin"])
.allow_credentials(true);

let routes = routes().with(cors).recover(handle_rejection);
let routes = routes().recover(handle_rejection).with(cors);
warp::serve(routes).run(([0, 0, 0, 0], 8000)).await;
}

0 comments on commit eb32a33

Please sign in to comment.