diff --git a/electron_app/src/electron-main.js b/electron_app/src/electron-main.js index eaedf6b3..aa92bb30 100644 --- a/electron_app/src/electron-main.js +++ b/electron_app/src/electron-main.js @@ -232,6 +232,10 @@ ipcMain.on('ipcCall', async function(ev, payload) { } break; case 'origin_migrate': + // NB. The code to call this has now been removed so this + // should never be called. This code itself has been removed + // with the migration to the riot-desktop repo, with the + // expectation that this will become the new home for this code. migratingOrigin = true; await migrateFromOldOrigin(); migratingOrigin = false; diff --git a/src/vector/index.js b/src/vector/index.js index c0cf2b46..12c0cfe8 100644 --- a/src/vector/index.js +++ b/src/vector/index.js @@ -191,14 +191,6 @@ async function loadApp() { console.log("Using Electron platform"); const plaf = new ElectronPlatform(); PlatformPeg.set(plaf); - - // Electron only: see if we need to do a one-time data - // migration - if (window.localStorage.getItem('mx_user_id') === null) { - console.log("Migrating session from old origin..."); - await plaf.migrateFromOldOrigin(); - console.log("Origin migration complete"); - } } else { console.log("Using Web platform"); PlatformPeg.set(new WebPlatform()); diff --git a/src/vector/platform/ElectronPlatform.js b/src/vector/platform/ElectronPlatform.js index eb5b2a86..1128c33f 100644 --- a/src/vector/platform/ElectronPlatform.js +++ b/src/vector/platform/ElectronPlatform.js @@ -355,10 +355,6 @@ export default class ElectronPlatform extends VectorBasePlatform { window.location.reload(false); } - async migrateFromOldOrigin() { - return this._ipcCall('origin_migrate'); - } - async _ipcCall(name, ...args) { const ipcCallId = ++this._nextIpcCallId; return new Promise((resolve, reject) => { diff --git a/src/vector/platform/VectorBasePlatform.js b/src/vector/platform/VectorBasePlatform.js index 32b43820..376b0a0e 100644 --- a/src/vector/platform/VectorBasePlatform.js +++ b/src/vector/platform/VectorBasePlatform.js @@ -173,12 +173,4 @@ export default class VectorBasePlatform extends BasePlatform { getDefaultDeviceDisplayName(): string { return _t("Unknown device"); } - - /** - * Migrate account data from a previous origin - * Used only for the electron app - */ - async migrateFromOldOrigin() { - return false; - } }