From 1c18d06aa3dc7efc4fdbeacb00102da23dd75be4 Mon Sep 17 00:00:00 2001 From: Randy Mackay Date: Mon, 6 Aug 2018 09:58:13 +0900 Subject: [PATCH] AR_AttitudeControl: move unnecessary else --- libraries/APM_Control/AR_AttitudeControl.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libraries/APM_Control/AR_AttitudeControl.cpp b/libraries/APM_Control/AR_AttitudeControl.cpp index 165cd3d085..2c14a0f651 100644 --- a/libraries/APM_Control/AR_AttitudeControl.cpp +++ b/libraries/APM_Control/AR_AttitudeControl.cpp @@ -476,12 +476,12 @@ float AR_AttitudeControl::get_throttle_out_stop(bool motor_limit_low, bool motor // update last time we thought we were stopped _stop_last_ms = now; return 0.0f; - } else { - // clear stopped system time - _stop_last_ms = 0; - // run speed controller to bring vehicle to stop - return get_throttle_out_speed(desired_speed_limited, motor_limit_low, motor_limit_high, cruise_speed, cruise_throttle, dt); } + + // clear stopped system time + _stop_last_ms = 0; + // run speed controller to bring vehicle to stop + return get_throttle_out_speed(desired_speed_limited, motor_limit_low, motor_limit_high, cruise_speed, cruise_throttle, dt); } // for balancebot