Skip to content

Commit 7eeac00

Browse files
committed
chore: Fix RSSI naming
1 parent 9726b18 commit 7eeac00

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

crates/buttplug_client/src/device.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,14 +233,14 @@ impl ButtplugClientDevice {
233233
self
234234
.device_features
235235
.iter()
236-
.any(|x| *x.feature().feature_type() == FeatureType::RSSI)
236+
.any(|x| *x.feature().feature_type() == FeatureType::Rssi)
237237
}
238238

239239
pub fn rssi_level(&self) -> ButtplugClientResultFuture<i8> {
240240
if let Some(rssi) = self
241241
.device_features
242242
.iter()
243-
.find(|x| *x.feature().feature_type() == FeatureType::RSSI)
243+
.find(|x| *x.feature().feature_type() == FeatureType::Rssi)
244244
{
245245
rssi.rssi_level()
246246
} else {

crates/buttplug_core/src/message/device_feature.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ pub enum FeatureType {
3838
// PositionWithSpeed
3939
// Sensor Types
4040
Battery,
41-
RSSI,
41+
Rssi,
4242
Button,
4343
Pressure,
4444
// Currently unused but possible sensor features:
@@ -110,7 +110,7 @@ impl TryFrom<FeatureType> for InputType {
110110
match value {
111111
FeatureType::Unknown => Ok(InputType::Unknown),
112112
FeatureType::Battery => Ok(InputType::Battery),
113-
FeatureType::RSSI => Ok(InputType::Rssi),
113+
FeatureType::Rssi => Ok(InputType::Rssi),
114114
FeatureType::Button => Ok(InputType::Button),
115115
FeatureType::Pressure => Ok(InputType::Pressure),
116116
_ => Err(format!(
@@ -143,7 +143,7 @@ impl From<InputType> for FeatureType {
143143
match value {
144144
InputType::Unknown => FeatureType::Unknown,
145145
InputType::Battery => FeatureType::Battery,
146-
InputType::Rssi => FeatureType::RSSI,
146+
InputType::Rssi => FeatureType::Rssi,
147147
InputType::Button => FeatureType::Button,
148148
InputType::Pressure => FeatureType::Pressure,
149149
}

0 commit comments

Comments
 (0)