Skip to content

Commit

Permalink
Merge pull request #441 from doudar/NoneFix
Browse files Browse the repository at this point in the history
Fixed bug where "none" hr still scanned
  • Loading branch information
doudar authored Jan 24, 2023
2 parents 6d38d0f + 5de9325 commit e4e0ed2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added
-
### Changed
-
- Fixed bug where "none" hr still scanned. Credit to @xpectnil for discovering.
### Hardware
-

Expand Down
4 changes: 2 additions & 2 deletions src/Main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,7 @@ void SS2K::rxSerial(void) {

void SS2K::checkBLEReconnect() {
static int bleCheck = 0;
if ((String(userConfig.getConnectedPowerMeter()) == "none") && ((String(userConfig.getConnectedPowerMeter()) == "none"))) { // Exit immediately if "none" and "none"
if ((String(userConfig.getConnectedHeartMonitor()) == "none") && ((String(userConfig.getConnectedPowerMeter()) == "none"))) { // Exit immediately if "none" and "none"
bleCheck = 0;
return;
}
Expand All @@ -574,7 +574,7 @@ void SS2K::checkBLEReconnect() {
bleCheck = 0;
return;
}
if (((String(userConfig.getConnectedPowerMeter()) == "none") && (spinBLEClient.connectedPM))) { // Exit if "none" HR and PM is connected
if (((String(userConfig.getConnectedHeartMonitor()) == "none") && (spinBLEClient.connectedPM))) { // Exit if "none" HR and PM is connected
bleCheck = 0;
return;
}
Expand Down

0 comments on commit e4e0ed2

Please sign in to comment.