Use .clone() instead of.as_slice().to_string()

This commit is contained in:
ProgramFOX 2014-12-05 21:12:20 +01:00
parent 86282022bd
commit e2e5536315

View file

@ -506,7 +506,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
// http://dom.spec.whatwg.org/#dom-document-characterset
fn CharacterSet(self) -> DOMString {
self.encoding_name.borrow().as_slice().to_string()
self.encoding_name.borrow().clone()
}
// http://dom.spec.whatwg.org/#dom-document-content_type