Heartbeat: Break from loop rather than returning

This makes sure we run the cleanup code at the bottom of the thread
pull/25/head
Paul Hollinsky 2020-09-01 16:32:54 -04:00
parent a325d8a12b
commit 8e999a0fb8
1 changed files with 1 additions and 1 deletions

View File

@ -240,7 +240,7 @@ bool Device::open() {
if(!receivedMessage && !settings->applyingSettings) { if(!receivedMessage && !settings->applyingSettings) {
if(!stopHeartbeatThread) if(!stopHeartbeatThread)
report(APIEvent::Type::DeviceDisconnected, APIEvent::Severity::Error); report(APIEvent::Type::DeviceDisconnected, APIEvent::Severity::Error);
return; break;
} }
} }
receivedMessage = false; receivedMessage = false;