Unverified Commit 44fb64fb authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #6909 from DonLakeFlyer/GeoFenceLoad

Plan GeoFence: Fix loading of files saved from version prior to Stable 3.4
parents dfabac0b dc10678d
......@@ -5,6 +5,9 @@ Note: This file only contains high level features or important fixes.
## 3.4
### 3.4.5 - Not yet released
* Plan GeoFence: Fix loading of fence from intermediate 3.4 code
* Orbit: Turn off for PX4 since still not supported
* Structure Scan: Fix loading of structure scan height
* ArduPilot: Fix location of planned home position when not connected to vehicle. Issue #6840.
### 3.4.4 - Stable
......
......@@ -232,7 +232,7 @@ bool PX4FirmwarePlugin::isCapable(const Vehicle *vehicle, FirmwareCapabilities c
{
int available = SetFlightModeCapability | PauseVehicleCapability | GuidedModeCapability;
if (vehicle->multiRotor() || vehicle->vtol()) {
available |= TakeoffVehicleCapability | OrbitModeCapability;
available |= TakeoffVehicleCapability;
}
return (capabilities & available) == capabilities;
......
......@@ -123,8 +123,9 @@ bool GeoFenceController::load(const QJsonObject& json, QString& errorString)
errorString.clear();
if (json.contains(JsonHelper::jsonVersionKey) && json[JsonHelper::jsonVersionKey].toInt() == 1) {
// We just ignore old version 1 data
if (!json.contains(JsonHelper::jsonVersionKey) ||
(json.contains(JsonHelper::jsonVersionKey) && json[JsonHelper::jsonVersionKey].toInt() == 1)) {
// We just ignore old version 1 or prior data
return true;
}
......
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