cors: add Set-Cookie to exposed headers

Signed-off-by: ATechnoHazard <amolele@gmail.com>
This commit is contained in:
Amogh Lele 2020-09-26 10:47:40 +05:30
parent 4dafd40fcf
commit 2aef9cb7a1
No known key found for this signature in database
GPG Key ID: F475143EDEDEBA3C

View File

@ -8,7 +8,9 @@ pub mod user;
pub fn fuel(rocket: Rocket) -> Rocket {
let mut rocket = rocket;
let cors = CorsOptions::default().to_cors().unwrap();
let mut cors_options = CorsOptions::default();
cors_options.expose_headers.insert("Set-Cookie".to_owned());
let cors = cors_options.to_cors().unwrap();
rocket = health::fuel(rocket);
rocket = paste::fuel(rocket);
rocket = user::fuel(rocket);