diff options
| author | diogo464 <[email protected]> | 2026-01-20 15:06:41 +0000 |
|---|---|---|
| committer | diogo464 <[email protected]> | 2026-01-20 15:06:41 +0000 |
| commit | 18cf7f77b0d1c93d9b24f1ba43183a81e3e5a81e (patch) | |
| tree | d4352b08f87dd51c4eddb2fd300cb2be13bd4e50 /src/entity_sensor.rs | |
| parent | 74e0f4ca0b0054e3317826f2af0932712d965671 (diff) | |
| parent | 8466e8720856786833099580931e7cc77d89d122 (diff) | |
Merge branch 'main' into embassy-gitembassy-git
Diffstat (limited to 'src/entity_sensor.rs')
| -rw-r--r-- | src/entity_sensor.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/entity_sensor.rs b/src/entity_sensor.rs index e221141..fd5e7f7 100644 --- a/src/entity_sensor.rs +++ b/src/entity_sensor.rs | |||
| @@ -18,8 +18,7 @@ impl StateClass { | |||
| 18 | } | 18 | } |
| 19 | } | 19 | } |
| 20 | 20 | ||
| 21 | #[derive(Debug, Clone, Copy, PartialEq, Eq)] | 21 | #[derive(Debug, Clone, Copy, PartialEq, Eq, Default)] |
| 22 | #[derive(Default)] | ||
| 23 | pub enum SensorClass { | 22 | pub enum SensorClass { |
| 24 | #[default] | 23 | #[default] |
| 25 | Generic, | 24 | Generic, |
| @@ -77,7 +76,6 @@ pub enum SensorClass { | |||
| 77 | Other(&'static str), | 76 | Other(&'static str), |
| 78 | } | 77 | } |
| 79 | 78 | ||
| 80 | |||
| 81 | impl SensorClass { | 79 | impl SensorClass { |
| 82 | pub fn as_str(&self) -> Option<&'static str> { | 80 | pub fn as_str(&self) -> Option<&'static str> { |
| 83 | match self { | 81 | match self { |
