diff options
Diffstat (limited to 'components/script/dom/blob.rs')
-rw-r--r-- | components/script/dom/blob.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/blob.rs b/components/script/dom/blob.rs index bfa85bb5784..7e2d539d163 100644 --- a/components/script/dom/blob.rs +++ b/components/script/dom/blob.rs @@ -82,14 +82,14 @@ impl Blob { } pub trait BlobHelpers { - fn read_out_buffer(self) -> Receiver<Option<Vec<u8>>> ; + fn read_out_buffer(self) -> Receiver<Vec<u8>>; fn read_out_type(self) -> DOMString; } impl<'a> BlobHelpers for &'a Blob { - fn read_out_buffer(self) -> Receiver<Option<Vec<u8>>> { + fn read_out_buffer(self) -> Receiver<Vec<u8>> { let (send, recv) = mpsc::channel(); - send.send(self.bytes.clone()).unwrap(); + send.send(self.bytes.clone().unwrap_or(vec![])).unwrap(); recv } fn read_out_type(self) -> DOMString { |