parent
6ab65f4247
commit
f1ad6f3bd3
|
@ -207,6 +207,7 @@ dependencies = [
|
|||
"serde_json",
|
||||
"serde_yaml",
|
||||
"tera",
|
||||
"v_htmlescape",
|
||||
"yarte",
|
||||
]
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@ serde_derive = "1"
|
|||
serde_json = "1"
|
||||
serde_yaml = "0.8"
|
||||
tera = { git = "https://github.com/Keats/tera" }
|
||||
v_htmlescape = "0.9.1"
|
||||
yarte = { git = "https://github.com/botika/yarte", features = ["bytes-buf", "fixed"] }
|
||||
|
||||
[build-dependencies]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
use std::io::Write;
|
||||
use v_htmlescape::escape;
|
||||
|
||||
use criterion;
|
||||
|
||||
|
@ -68,8 +69,8 @@ pub fn teams(b: &mut criterion::Bencher<'_>, _: &usize) {
|
|||
&mut output,
|
||||
"<li class=\"{champion}\">
|
||||
<b>{name}</b>: {score}",
|
||||
champion = champion,
|
||||
name = team.name,
|
||||
champion = escape(champion),
|
||||
name = escape(&team.name),
|
||||
score = team.score
|
||||
)
|
||||
.unwrap();
|
||||
|
|
Loading…
Reference in New Issue