Skip to content

Commit 506a489

Browse files
chip::to_underlying is missing [air-quality-sensor-manager] (project-chip#30057)
* chip::to_underlying is missing * Apply suggested fix to remove unnecessary cast. --------- Co-authored-by: Boris Zbarsky <bzbarsky@apple.com>
1 parent 6076317 commit 506a489

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples/air-quality-sensor-app/air-quality-sensor-common/src/air-quality-sensor-manager.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ void AirQualitySensorManager::Init()
136136

137137
void AirQualitySensorManager::OnAirQualityChangeHandler(AirQualityEnum newValue)
138138
{
139-
mAirQualityInstance.UpdateAirQuality(static_cast<AirQualityEnum>(newValue));
140-
ChipLogDetail(NotSpecified, "Updated AirQuality value: %huu", newValue);
139+
mAirQualityInstance.UpdateAirQuality(newValue);
140+
ChipLogDetail(NotSpecified, "Updated AirQuality value: %huu", chip::to_underlying(newValue));
141141
}
142142

143143
void AirQualitySensorManager::OnCarbonDioxideMeasurementChangeHandler(float newValue)

0 commit comments

Comments
 (0)