Skip to content

Commit

Permalink
Change hardcoded check on first inverter
Browse files Browse the repository at this point in the history
The for-loop of all inverters did only check for inverters[0] if it was confirmed.
  • Loading branch information
sircuri authored Sep 4, 2017
1 parent 28dfab7 commit 4bf6df5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion MQTTPublisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ void MQTTPublisher::handle()
auto inverters = goodweCommunicator->getInvertersInfo();
for (char cnt = 0; cnt < inverters.size(); cnt++)
{
if (inverters[0].addressConfirmed)
if (inverters[cnt].addressConfirmed)
{
auto prependTopic = (String("goodwe/") + String(inverters[cnt].serialNumber));
if (debugMode)
Expand Down

0 comments on commit 4bf6df5

Please sign in to comment.