return empty bytes object vs None on exception
This commit is contained in:
1 parent
32cfc34c37
commit
d38c30011c
1 file changed
+3
@@ -293,6 +293,9 @@ class PollingCoordinator(DataUpdateCoordinator):
|
||||
self.logger.warning(
|
||||
"Needed to disconnect due to error: %s (This can also be the case if you used device controls)", err
|
||||
)
|
||||
|
||||
# caught an exception, return empty bytes object
|
||||
return bytes()
|
||||
|
||||
def _notification_handler(self, _sender: int, data: bytearray):
|
||||
"""Handle bt data."""
|
||||
|
||||
Reference in new issue
Block a user