Store the encoding in the Document rather than its name.

This commit is contained in:
Ms2ger 2016-03-18 16:22:29 +01:00
parent e551ea7322
commit b1cd28e9c6
3 changed files with 40 additions and 40 deletions

View file

@ -1696,7 +1696,7 @@ impl Node {
NodeTypeId::Document(_) => {
let node_doc = node.downcast::<Document>().unwrap();
let copy_doc = copy.downcast::<Document>().unwrap();
copy_doc.set_encoding_name(node_doc.encoding_name().clone());
copy_doc.set_encoding(node_doc.encoding());
copy_doc.set_quirks_mode(node_doc.quirks_mode());
},
NodeTypeId::Element(..) => {