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

only set the dirty flag if something was actually changed

This commit is contained in:
Hubert Chathi
2019-02-21 22:58:00 -05:00
parent 33a3506981
commit d2557bc943

View File

@@ -475,11 +475,11 @@ export default class DeviceList {
if (!this._deviceTrackingStatus[userId]) { if (!this._deviceTrackingStatus[userId]) {
logger.log('Now tracking device list for ' + userId); logger.log('Now tracking device list for ' + userId);
this._deviceTrackingStatus[userId] = TRACKING_STATUS_PENDING_DOWNLOAD; this._deviceTrackingStatus[userId] = TRACKING_STATUS_PENDING_DOWNLOAD;
}
// we don't yet persist the tracking status, since there may be a lot // we don't yet persist the tracking status, since there may be a lot
// of calls; we save all data together once the sync is done // of calls; we save all data together once the sync is done
this._dirty = true; this._dirty = true;
} }
}
/** /**
* Mark the given user as no longer being tracked for device-list updates. * Mark the given user as no longer being tracked for device-list updates.