Skip to content

Commit

Permalink
fix: Fix configure failing for SONOFF ZBMINI-L and ZBMINIL2 Koenkk/zi…
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenkk committed Aug 30, 2024
1 parent 59dece5 commit 67682e9
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/devices/sonoff.ts
Original file line number Diff line number Diff line change
Expand Up @@ -573,7 +573,10 @@ const definitions: Definition[] = [
// Zigbee-herdsmans responds to the checkin message which causes the device
// to poll slower.
// https://github.com/Koenkk/zigbee2mqtt/issues/11676
await device.getEndpoint(1).unbind('genPollCtrl', coordinatorEndpoint);
const endpoint = device.getEndpoint(1);
if (endpoint.binds.some((b) => b.cluster.name === 'genPollCtrl')) {
await device.getEndpoint(1).unbind('genPollCtrl', coordinatorEndpoint);
}
device.powerSource = 'Mains (single phase)';
device.save();
},
Expand All @@ -589,7 +592,10 @@ const definitions: Definition[] = [
// Zigbee-herdsmans responds to the checkin message which causes the device
// to poll slower.
// https://github.com/Koenkk/zigbee2mqtt/issues/11676
await device.getEndpoint(1).unbind('genPollCtrl', coordinatorEndpoint);
const endpoint = device.getEndpoint(1);
if (endpoint.binds.some((b) => b.cluster.name === 'genPollCtrl')) {
await device.getEndpoint(1).unbind('genPollCtrl', coordinatorEndpoint);
}
device.powerSource = 'Mains (single phase)';
device.save();
},
Expand Down

0 comments on commit 67682e9

Please sign in to comment.