File tree Expand file tree Collapse file tree 8 files changed +8
-8
lines changed
homeassistant/components/tuya Expand file tree Collapse file tree 8 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -184,7 +184,7 @@ def changed_by(self) -> str | None:
184184 """Last change triggered by."""
185185 if self ._changed_by_wrapper is None :
186186 return None
187- return self ._changed_by_wrapper . read_device_status (self .device )
187+ return self ._read_wrapper (self ._changed_by_wrapper )
188188
189189 async def async_alarm_disarm (self , code : str | None = None ) -> None :
190190 """Send Disarm command."""
Original file line number Diff line number Diff line change @@ -461,4 +461,4 @@ def __init__(
461461 @property
462462 def is_on (self ) -> bool | None :
463463 """Return true if sensor is on."""
464- return self ._dpcode_wrapper . read_device_status (self .device )
464+ return self ._read_wrapper (self ._dpcode_wrapper )
Original file line number Diff line number Diff line change @@ -551,7 +551,7 @@ def _validate_device_class_unit(self) -> None:
551551 @property
552552 def native_value (self ) -> float | None :
553553 """Return the entity value to represent the entity state."""
554- return self ._dpcode_wrapper . read_device_status (self .device )
554+ return self ._read_wrapper (self ._dpcode_wrapper )
555555
556556 async def async_set_native_value (self , value : float ) -> None :
557557 """Set new value."""
Original file line number Diff line number Diff line change @@ -405,7 +405,7 @@ def __init__(
405405 @property
406406 def current_option (self ) -> str | None :
407407 """Return the selected entity option to represent the entity state."""
408- return self ._dpcode_wrapper . read_device_status (self .device )
408+ return self ._read_wrapper (self ._dpcode_wrapper )
409409
410410 async def async_select_option (self , option : str ) -> None :
411411 """Change the selected option."""
Original file line number Diff line number Diff line change @@ -1851,4 +1851,4 @@ def _validate_device_class_unit(self) -> None:
18511851 @property
18521852 def native_value (self ) -> StateType :
18531853 """Return the value reported by the sensor."""
1854- return self ._dpcode_wrapper . read_device_status (self .device )
1854+ return self ._read_wrapper (self ._dpcode_wrapper )
Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ def __init__(
105105 @property
106106 def is_on (self ) -> bool | None :
107107 """Return true if siren is on."""
108- return self ._dpcode_wrapper . read_device_status (self .device )
108+ return self ._read_wrapper (self ._dpcode_wrapper )
109109
110110 async def async_turn_on (self , ** kwargs : Any ) -> None :
111111 """Turn the siren on."""
Original file line number Diff line number Diff line change @@ -1038,7 +1038,7 @@ def __init__(
10381038 @property
10391039 def is_on (self ) -> bool | None :
10401040 """Return true if switch is on."""
1041- return self ._dpcode_wrapper . read_device_status (self .device )
1041+ return self ._read_wrapper (self ._dpcode_wrapper )
10421042
10431043 async def async_turn_on (self , ** kwargs : Any ) -> None :
10441044 """Turn the switch on."""
Original file line number Diff line number Diff line change @@ -133,7 +133,7 @@ def __init__(
133133 @property
134134 def is_closed (self ) -> bool | None :
135135 """Return if the valve is closed."""
136- if (is_open := self ._dpcode_wrapper . read_device_status (self .device )) is None :
136+ if (is_open := self ._read_wrapper (self ._dpcode_wrapper )) is None :
137137 return None
138138 return not is_open
139139
You can’t perform that action at this time.
0 commit comments