aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar CrunkLord420 <crunklord420@lolcow.email>2021-12-12 04:07:46 +0000
committerLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2021-12-14 20:49:43 +0100
commit228f6b2b34913077259e2d54036154a6d6f5bd10 (patch)
treea0816b99d10226e4778456e61479e740ede5c17a
parent95317478ccb9baab3d1797d693e4c33008434b50 (diff)
downloadaskama-228f6b2b34913077259e2d54036154a6d6f5bd10.tar.gz
askama-228f6b2b34913077259e2d54036154a6d6f5bd10.tar.bz2
askama-228f6b2b34913077259e2d54036154a6d6f5bd10.zip
updated for actix-web 4.0.0-beta.14
-rw-r--r--askama_actix/Cargo.toml4
-rw-r--r--askama_shared/src/generator.rs3
2 files changed, 4 insertions, 3 deletions
diff --git a/askama_actix/Cargo.toml b/askama_actix/Cargo.toml
index 3c89f2a..06fd2b3 100644
--- a/askama_actix/Cargo.toml
+++ b/askama_actix/Cargo.toml
@@ -13,11 +13,11 @@ readme = "README.md"
edition = "2018"
[dependencies]
-actix-web = { version = "4.0.0-beta.10", default-features = false }
+actix-web = { version = "4.0.0-beta.14", default-features = false }
askama = { version = "0.11.0", path = "../askama", default-features = false, features = ["with-actix-web", "mime", "mime_guess"] }
bytes = { version = "1" }
futures-util = { version = "0.3" }
[dev-dependencies]
actix-rt = { version = "2", default-features = false }
-actix-test = "0.1.0-beta.5"
+actix-test = "0.1.0-beta.8"
diff --git a/askama_shared/src/generator.rs b/askama_shared/src/generator.rs
index d264897..41b81df 100644
--- a/askama_shared/src/generator.rs
+++ b/askama_shared/src/generator.rs
@@ -213,9 +213,10 @@ impl<'a, S: std::hash::BuildHasher> Generator<'a, S> {
// Implement Actix-web's `Responder`.
fn impl_actix_web_responder(&mut self, buf: &mut Buffer) -> Result<(), CompileError> {
self.write_header(buf, "::actix_web::Responder", None)?;
+ buf.writeln("type Body = actix_web::body::BoxBody;")?;
buf.writeln(
"fn respond_to(self, _req: &::actix_web::HttpRequest) \
- -> ::actix_web::HttpResponse {",
+ -> ::actix_web::HttpResponse<Self::Body> {",
)?;
buf.writeln("use ::askama_actix::TemplateToResponse;")?;