Skip to content

Commit 9804635

Browse files
authored
Merge pull request #1315 from custom-components/Packet_id
Fix last packet id
2 parents f4b8e58 + bbbcd76 commit 9804635

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

custom_components/ble_monitor/manifest.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@
1414
"btsocket>=0.2.0",
1515
"pyric>=0.1.6.3"
1616
],
17-
"version": "12.9.0"
17+
"version": "12.9.1"
1818
}

custom_components/ble_monitor/sensor.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -990,7 +990,7 @@ def collect(self, data, period_cnt, batt_attr=None):
990990
return
991991
self._state = data[self.entity_description.key]
992992
self._extra_state_attributes["sensor_type"] = data["type"]
993-
self._extra_state_attributes["last_packet id"] = data["packet"]
993+
self._extra_state_attributes["last_packet_id"] = data["packet"]
994994
self._extra_state_attributes["firmware"] = data["firmware"]
995995
self._extra_state_attributes['mac_address' if self.is_beacon else 'uuid'] = dict_get_or_normalize(
996996
data, CONF_MAC, CONF_UUID
@@ -1105,7 +1105,7 @@ def collect(self, data, period_cnt, batt_attr=None):
11051105
else:
11061106
self.pending_update = False
11071107
return
1108-
self._extra_state_attributes["last_packet id"] = data["packet"]
1108+
self._extra_state_attributes["last_packet_id"] = data["packet"]
11091109
self._extra_state_attributes["firmware"] = data["firmware"]
11101110
self._extra_state_attributes['mac_address' if self.is_beacon else 'uuid'] = dict_get_or_normalize(
11111111
data, CONF_MAC, CONF_UUID

0 commit comments

Comments
 (0)