mirror of
https://github.com/zadam/trilium.git
synced 2025-11-16 10:15:52 +01:00
db upgrades are now handled transparently in the background without bothering the user, closes #119
This commit is contained in:
@@ -1,25 +0,0 @@
|
||||
"use strict";
|
||||
|
||||
const optionService = require('../../services/options');
|
||||
const migrationService = require('../../services/migration');
|
||||
const appInfo = require('../../services/app_info');
|
||||
|
||||
async function getMigrationInfo() {
|
||||
return {
|
||||
dbVersion: parseInt(await optionService.getOption('dbVersion')),
|
||||
appDbVersion: appInfo.dbVersion
|
||||
};
|
||||
}
|
||||
|
||||
async function executeMigration() {
|
||||
const migrations = await migrationService.migrate();
|
||||
|
||||
return {
|
||||
migrations: migrations
|
||||
};
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
getMigrationInfo,
|
||||
executeMigration
|
||||
};
|
||||
Reference in New Issue
Block a user