aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/request.rs
diff options
context:
space:
mode:
authorOJ Kwon <kwon.ohjoong@gmail.com>2018-03-23 12:11:41 -0700
committerOJ Kwon <kwon.ohjoong@gmail.com>2018-03-23 23:12:21 -0700
commitc0b5eeef575356b05472a5a6759c9eaedbe9cd4d (patch)
tree41a78f8f681402d0262238669e07aa34f76dee2d /components/script/dom/request.rs
parent72f326b22bfa9dfae30941883979fd9f3090d044 (diff)
downloadservo-c0b5eeef575356b05472a5a6759c9eaedbe9cd4d.tar.gz
servo-c0b5eeef575356b05472a5a6759c9eaedbe9cd4d.zip
feat(webidl): expose arraybuffer overload in body idl
Diffstat (limited to 'components/script/dom/request.rs')
-rw-r--r--components/script/dom/request.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/components/script/dom/request.rs b/components/script/dom/request.rs
index 85998533ae9..b3bb2f1afe1 100644
--- a/components/script/dom/request.rs
+++ b/components/script/dom/request.rs
@@ -611,6 +611,12 @@ impl RequestMethods for Request {
fn Json(&self) -> Rc<Promise> {
consume_body(self, BodyType::Json)
}
+
+ #[allow(unrooted_must_root)]
+ // https://fetch.spec.whatwg.org/#dom-body-arraybuffer
+ fn ArrayBuffer(&self) -> Rc<Promise> {
+ consume_body(self, BodyType::ArrayBuffer)
+ }
}
impl BodyOperations for Request {