1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-11-26 17:03:12 +03:00

Stop devicelist when client is stopped

To avoid the devicelist trying to save after the client has been
stopped

Hopefully will fix random test failures on node 11.
This commit is contained in:
David Baker
2018-10-25 19:00:03 +01:00
parent 870e96a1df
commit 88b39f4b67
3 changed files with 19 additions and 1 deletions

View File

@@ -146,6 +146,12 @@ export default class DeviceList {
}
}
stop() {
if (this._saveTimer !== null) {
clearTimeout(this._saveTimer);
}
}
/**
* Save the device tracking state to storage, if any changes are
* pending other than updating the sync token