MOBILE-3320 core: Standarize "initialize" usage
parent
152caaf707
commit
6d1d4a34ce
|
@ -21,11 +21,11 @@ import { CoreSites } from '@services/sites';
|
||||||
|
|
||||||
export default async function(): Promise<void> {
|
export default async function(): Promise<void> {
|
||||||
await Promise.all([
|
await Promise.all([
|
||||||
CoreApp.instance.initialiseDatabase(),
|
CoreApp.instance.initializeDatabase(),
|
||||||
CoreConfig.instance.initialiseDatabase(),
|
CoreConfig.instance.initializeDatabase(),
|
||||||
CoreCronDelegate.instance.initialiseDatabase(),
|
CoreCronDelegate.instance.initializeDatabase(),
|
||||||
CoreFilepool.instance.initialiseDatabase(),
|
CoreFilepool.instance.initializeDatabase(),
|
||||||
CoreLocalNotifications.instance.initialiseDatabase(),
|
CoreLocalNotifications.instance.initializeDatabase(),
|
||||||
CoreSites.instance.initialiseDatabase(),
|
CoreSites.instance.initializeDatabase(),
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -85,9 +85,9 @@ export class CoreAppProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialise database.
|
* Initialize database.
|
||||||
*/
|
*/
|
||||||
async initialiseDatabase(): Promise<void> {
|
async initializeDatabase(): Promise<void> {
|
||||||
await this.db.createTableFromSchema(SCHEMA_VERSIONS_TABLE_SCHEMA);
|
await this.db.createTableFromSchema(SCHEMA_VERSIONS_TABLE_SCHEMA);
|
||||||
|
|
||||||
this.resolveSchemaVersionsManager({
|
this.resolveSchemaVersionsManager({
|
||||||
|
|
|
@ -34,9 +34,9 @@ export class CoreConfigProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialise database.
|
* Initialize database.
|
||||||
*/
|
*/
|
||||||
async initialiseDatabase(): Promise<void> {
|
async initializeDatabase(): Promise<void> {
|
||||||
try {
|
try {
|
||||||
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
@ -58,9 +58,9 @@ export class CoreCronDelegateService {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialise database.
|
* Initialize database.
|
||||||
*/
|
*/
|
||||||
async initialiseDatabase(): Promise<void> {
|
async initializeDatabase(): Promise<void> {
|
||||||
try {
|
try {
|
||||||
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
@ -101,9 +101,9 @@ export class CoreFilepoolProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialise database.
|
* Initialize database.
|
||||||
*/
|
*/
|
||||||
async initialiseDatabase(): Promise<void> {
|
async initializeDatabase(): Promise<void> {
|
||||||
try {
|
try {
|
||||||
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
@ -69,9 +69,9 @@ export class CoreLocalNotificationsProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialise database.
|
* Initialize database.
|
||||||
*/
|
*/
|
||||||
async initialiseDatabase(): Promise<void> {
|
async initializeDatabase(): Promise<void> {
|
||||||
try {
|
try {
|
||||||
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
@ -94,9 +94,9 @@ export class CoreSitesProvider {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialise database.
|
* Initialize database.
|
||||||
*/
|
*/
|
||||||
async initialiseDatabase(): Promise<void> {
|
async initializeDatabase(): Promise<void> {
|
||||||
try {
|
try {
|
||||||
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
await CoreApp.instance.createTablesFromSchema(APP_SCHEMA);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
Loading…
Reference in New Issue