aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/dom/formdata.rs
diff options
context:
space:
mode:
authorbors-servo <release+servo@mozilla.com>2014-06-13 14:33:03 -0400
committerbors-servo <release+servo@mozilla.com>2014-06-13 14:33:03 -0400
commit7ed504189198ac2f59c396d5872046ac7c9578b3 (patch)
tree1943813d56e57e8bdb38189351f1b51019c5de68 /src/components/script/dom/formdata.rs
parentc0576108c5fb82410faa23dc1cccff2dce56d698 (diff)
parentbda29ade0912f7e17958f2f43dbe068bbb2bfd51 (diff)
downloadservo-7ed504189198ac2f59c396d5872046ac7c9578b3.tar.gz
servo-7ed504189198ac2f59c396d5872046ac7c9578b3.zip
auto merge of #2649 : ebalint/servo/2580_JS_T_unrooted_replace, r=jdm
removed .clone() calls modified from_rooted method parameter: T to &T
Diffstat (limited to 'src/components/script/dom/formdata.rs')
-rw-r--r--src/components/script/dom/formdata.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/components/script/dom/formdata.rs b/src/components/script/dom/formdata.rs
index eeea9cc32f0..a20d1e66872 100644
--- a/src/components/script/dom/formdata.rs
+++ b/src/components/script/dom/formdata.rs
@@ -33,7 +33,7 @@ impl FormData {
FormData {
data: Traceable::new(RefCell::new(HashMap::new())),
reflector_: Reflector::new(),
- window: window.unrooted(),
+ window: JS::from_rooted(window),
form: form.unrooted(),
}
}
@@ -55,7 +55,7 @@ pub trait FormDataMethods {
impl<'a> FormDataMethods for JSRef<'a, FormData> {
fn Append(&self, name: DOMString, value: &JSRef<Blob>, filename: Option<DOMString>) {
let blob = BlobData {
- blob: value.unrooted(),
+ blob: JS::from_rooted(value),
name: filename.unwrap_or("default".to_string())
};
self.data.deref().borrow_mut().insert(name.clone(), blob);