1
0
mirror of https://github.com/actix/examples synced 2024-11-23 22:41:07 +01:00

Fixes Incorrect Return of body in multipart example (#407)

This commit is contained in:
Arnav Jindal 2021-03-03 22:08:29 +05:30 committed by GitHub
parent 7487a81e90
commit e86d5ff214
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 3 deletions

View File

@ -35,7 +35,9 @@ fn index() -> HttpResponse {
</body> </body>
</html>"#; </html>"#;
HttpResponse::Ok().body(html) HttpResponse::Ok()
.content_type("text/html; charset=utf-8")
.body(html)
} }
#[actix_web::main] #[actix_web::main]

View File

@ -69,7 +69,9 @@ fn index() -> HttpResponse {
</script> </script>
</html>"#; </html>"#;
HttpResponse::Ok().body(html) HttpResponse::Ok()
.content_type("text/html; charset=utf-8")
.body(html)
} }
#[actix_web::main] #[actix_web::main]

View File

@ -37,7 +37,9 @@ fn index() -> HttpResponse {
</body> </body>
</html>"#; </html>"#;
HttpResponse::Ok().body(html) HttpResponse::Ok()
.content_type("text/html; charset=utf-8")
.body(html)
} }
#[actix_web::main] #[actix_web::main]