mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
clippy: Fix needless borrow warnings (#31813)
This commit is contained in:
parent
694e86ecff
commit
3e63f8d6ee
42 changed files with 151 additions and 157 deletions
|
@ -157,14 +157,14 @@ impl AsyncBluetoothListener for BluetoothRemoteGATTService {
|
|||
BluetoothResponse::GetCharacteristics(characteristics_vec, single) => {
|
||||
if single {
|
||||
promise.resolve_native(
|
||||
&device.get_or_create_characteristic(&characteristics_vec[0], &self),
|
||||
&device.get_or_create_characteristic(&characteristics_vec[0], self),
|
||||
);
|
||||
return;
|
||||
}
|
||||
let mut characteristics = vec![];
|
||||
for characteristic in characteristics_vec {
|
||||
let bt_characteristic =
|
||||
device.get_or_create_characteristic(&characteristic, &self);
|
||||
device.get_or_create_characteristic(&characteristic, self);
|
||||
characteristics.push(bt_characteristic);
|
||||
}
|
||||
promise.resolve_native(&characteristics);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue