Don't send disconnect to a closed device

This commit is contained in:
Valerie Young 2019-01-11 16:47:42 -05:00
parent 328e4480f6
commit f2f4af2590

View file

@ -107,6 +107,7 @@ class GdxFor {
disconnect () { disconnect () {
if (this._device) { if (this._device) {
this._device.close(); this._device.close();
this._device = null;
this._sensorsEnabled = false; this._sensorsEnabled = false;
} }
} }