Use the power-getter rather than accessing the property directly

This commit is contained in:
Kevin Andersen 2019-04-09 14:52:41 -04:00
parent d9e0267fa0
commit 41873bf7bf

View file

@ -471,7 +471,7 @@ class BoostMotor {
* @param {number} direction - rotate in this direction * @param {number} direction - rotate in this direction
*/ */
turnOnForDegrees (degrees, direction) { turnOnForDegrees (degrees, direction) {
if (this._power === 0) { if (this.power === 0) {
this.pendingPromiseFunction(); this.pendingPromiseFunction();
return; return;
} }