diff options
Diffstat (limited to '')
-rw-r--r-- | askama/src/generator.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/askama/src/generator.rs b/askama/src/generator.rs index 85896c4..c3ba454 100644 --- a/askama/src/generator.rs +++ b/askama/src/generator.rs @@ -80,7 +80,7 @@ impl Generator { fn visit_var(&mut self, s: &[u8]) { let s = str::from_utf8(s).unwrap(); if self.locals.contains(s) { - self.write(&format!("{}", s)); + self.write(&s); } else { self.write(&format!("self.{}", s)); } @@ -157,7 +157,7 @@ impl Generator { let targets = self.visit_target(var); for name in &targets { self.locals.insert(name.clone()); - self.write(&format!("{}", name)); + self.write(name); } self.write(" in &"); self.visit_expr(iter); |