# HG changeset patch # User Goffi # Date 1551439054 -3600 # Node ID 11afbbce40d1f8434a7b3b3b264883b6690c16e1 # Parent 5284be4c601b69a38d2ca0f444d3c8b8b3e5cbb8 plugin XEP-0384: removed _purgeOldData temporary hack, it should not be useful anymore diff -r 5284be4c601b -r 11afbbce40d1 sat/plugins/plugin_xep_0384.py --- a/sat/plugins/plugin_xep_0384.py Fri Mar 01 12:16:57 2019 +0100 +++ b/sat/plugins/plugin_xep_0384.py Fri Mar 01 12:17:34 2019 +0100 @@ -538,26 +538,10 @@ defer.returnValue(xmlui) @defer.inlineCallbacks - def _purgeOldData(self, client, persistent_dict): - # FIXME: temporary method to deal with data change in omemo module - # We remove the old data, which is acceptable as - # no release of SàT (beside alpha versions) has been done - # since this data has been used. - # /!\ this method must be removed before 0.7 release /!\ - log.warning(u"FIXME: Using temporary purgeOldData code, to be removed before 0.7 release.") - - state = yield persistent_dict.get(KEY_STATE) - if state and "version" not in state: - log.info(u"Old data found, purging it") - self.host.memory.storage.delPrivateNamespace("XEP-0384", binary=True, - profile=client.profile) - - @defer.inlineCallbacks def profileConnected(self, client): client._xep_0384_ready = defer.Deferred() # we first need to get devices ids (including our own) persistent_dict = persistent.LazyPersistentBinaryDict("XEP-0384", client.profile) - yield self._purgeOldData(client, persistent_dict) # all known devices of profile devices = yield self.getDevices(client) # and our own device id