Unverified Commit 6423d117 authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #8545 from alexeylysenko/remove_unreachable_code

Fixed suspicious if-expression
parents 26fec0a3 c39824f5
...@@ -167,14 +167,10 @@ void VisualMissionItem::_updateTerrainAltitude(void) ...@@ -167,14 +167,10 @@ void VisualMissionItem::_updateTerrainAltitude(void)
return; return;
} }
if (!_flyView && specifiesCoordinate() && coordinate().isValid()) { if (!_flyView && specifiesCoordinate() && coordinate().isValid()) {
if (specifiesCoordinate()) { // We use a timer so that any additional requests before the timer fires result in only a single request
if (coordinate().isValid()) { _updateTerrainTimer.start();
// We use a timer so that any additional requests before the timer fires result in only a single request } else {
_updateTerrainTimer.start(); _terrainAltitude = qQNaN();
}
} else {
_terrainAltitude = qQNaN();
}
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment