mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Fix BluetoothPermissionResult return state
This commit is contained in:
parent
f7e86d2d0e
commit
b1d388a991
2 changed files with 4 additions and 3 deletions
|
@ -215,12 +215,12 @@ impl Bluetooth {
|
|||
let option = RequestDeviceoptions::new(BluetoothScanfilterSequence::new(uuid_filters),
|
||||
ServiceUUIDSequence::new(optional_services_uuids));
|
||||
|
||||
// Step 3 - 5
|
||||
// Step 4 - 5.
|
||||
if let PermissionState::Denied = get_descriptor_permission_state(PermissionName::Bluetooth, None) {
|
||||
return p.reject_error(p.global().get_cx(), Error::NotFound);
|
||||
}
|
||||
|
||||
// Note: Steps 6 - 8 are implemented in
|
||||
// Note: Step 3, 6 - 8 are implemented in
|
||||
// components/net/bluetooth_thread.rs in request_device function.
|
||||
self.get_bluetooth_thread().send(BluetoothRequest::RequestDevice(option, sender)).unwrap();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue