chiark
/
gitweb
/
~ianmdlvl
/
otter.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
768ebb9
)
Special client rendering: Fix quoting of JSON payload
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Fri, 15 Apr 2022 17:54:07 +0000
(18:54 +0100)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Fri, 15 Apr 2022 19:39:28 +0000
(20:39 +0100)
The needs to be in " " (and the JS will evaluate it).
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
src/pcrender.rs
patch
|
blob
|
history
diff --git
a/src/pcrender.rs
b/src/pcrender.rs
index 5315d07b026c4e9404e489f04484c598dc836bab..e84f816685f8345413ac18122a4ca4328da62e06 100644
(file)
--- a/
src/pcrender.rs
+++ b/
src/pcrender.rs
@@
-209,7
+209,7
@@
impl PieceRenderInstructions {
if let Some(special) = &special {
let special = serde_json::to_string(&special).map_err(IE::JSONEncode)?;
hwrite!(&mut defs,
- r##" data-special=
{}
"##,
+ r##" data-special=
"{}"
"##,
Html::from_txt(&special))?;
}
hwrite!(&mut defs,