Merge pull request #3457 from dpalou/MOBILE-4081

MOBILE-4081 core: Fix site already migrated error
main
Pau Ferrer Ocaña 2022-11-22 13:05:15 +01:00 committed by GitHub
commit 0788664be6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 7 deletions

View File

@ -84,7 +84,6 @@ export class CoreSitesProvider {
protected sessionRestored = false;
protected currentSite?: CoreSite;
protected sites: { [s: string]: CoreSite } = {};
protected sitesMigrated: { [s: string]: boolean } = {};
protected siteSchemasMigration: { [siteId: string]: Promise<void> } = {};
protected siteSchemas: { [name: string]: CoreRegisteredSiteSchema } = {};
protected pluginsSiteSchemas: { [name: string]: CoreRegisteredSiteSchema } = {};
@ -1721,12 +1720,6 @@ export class CoreSitesProvider {
return this.siteSchemasMigration[siteId];
}
if (this.sitesMigrated[siteId] !== undefined) {
throw new CoreError('Site already migrated.');
}
this.sitesMigrated[siteId] = true;
this.logger.debug(`Migrating all schemas of ${siteId}`);
// First create tables not registerd with name/version.