diff --git a/src/Waypoint.cc b/src/Waypoint.cc index 33e0bf62a8b663a29fd81427e2b427883fd0d93d..4a96042c9fe5cb4c867ba53bd5580d2e22081975 100644 --- a/src/Waypoint.cc +++ b/src/Waypoint.cc @@ -194,11 +194,9 @@ void Waypoint::setAction(MAV_CMD action) // Flick defaults according to WP type - switch (this->action) { - case MAV_CMD_NAV_TAKEOFF: + if (this->action == MAV_CMD_NAV_TAKEOFF) { // We default to 15 degrees minimum takeoff pitch this->param1 = 15.0; - break; } emit changed(this);