aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/bluetoothremotegattdescriptor.rs
diff options
context:
space:
mode:
authorzakorgy <zakorgy@inf.u-szeged.hu>2016-07-21 12:41:47 +0200
committerzakorgyula <gyula.zakor@gmail.com>2016-07-27 15:02:01 +0200
commitb4db14471bb6273e681a7f4945a4f8d0d9a6c8ea (patch)
tree6641b4f5f2b93ce772429bcfc1ec49a4371caa7e /components/script/dom/bluetoothremotegattdescriptor.rs
parentd8991496c6ddcce3c93ba36d36619a3200626c1f (diff)
downloadservo-b4db14471bb6273e681a7f4945a4f8d0d9a6c8ea.tar.gz
servo-b4db14471bb6273e681a7f4945a4f8d0d9a6c8ea.zip
Refactor Bluetooth error handling
Diffstat (limited to 'components/script/dom/bluetoothremotegattdescriptor.rs')
-rw-r--r--components/script/dom/bluetoothremotegattdescriptor.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/bluetoothremotegattdescriptor.rs b/components/script/dom/bluetoothremotegattdescriptor.rs
index f821d4aca2d..0ba52181b48 100644
--- a/components/script/dom/bluetoothremotegattdescriptor.rs
+++ b/components/script/dom/bluetoothremotegattdescriptor.rs
@@ -11,7 +11,7 @@ use dom::bindings::codegen::Bindings::BluetoothRemoteGATTDescriptorBinding;
use dom::bindings::codegen::Bindings::BluetoothRemoteGATTDescriptorBinding::BluetoothRemoteGATTDescriptorMethods;
use dom::bindings::codegen::Bindings::BluetoothRemoteGATTServerBinding::BluetoothRemoteGATTServerMethods;
use dom::bindings::codegen::Bindings::BluetoothRemoteGATTServiceBinding::BluetoothRemoteGATTServiceMethods;
-use dom::bindings::error::Error::{InvalidModification, Network, Security, Type};
+use dom::bindings::error::Error::{self, InvalidModification, Network, Security};
use dom::bindings::error::{Fallible, ErrorResult};
use dom::bindings::global::GlobalRef;
use dom::bindings::js::{JS, MutHeap, Root};
@@ -101,7 +101,7 @@ impl BluetoothRemoteGATTDescriptorMethods for BluetoothRemoteGATTDescriptor {
ByteString::new(val)
},
Err(error) => {
- return Err(Type(error))
+ return Err(Error::from(error))
},
};
*self.value.borrow_mut() = Some(value.clone());
@@ -126,7 +126,7 @@ impl BluetoothRemoteGATTDescriptorMethods for BluetoothRemoteGATTDescriptor {
match result {
Ok(_) => Ok(()),
Err(error) => {
- Err(Type(error))
+ Err(Error::from(error))
},
}
}