mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 12:19:41 +00:00
Support database upgrades in Database.open
This commit is contained in:
@@ -147,8 +147,15 @@ const database = {
|
||||
migrations,
|
||||
};
|
||||
|
||||
exports.run = ({ Backbone } = {}) =>
|
||||
runMigrations({ Backbone, database });
|
||||
exports.run = ({ Backbone, databaseName } = {}) =>
|
||||
runMigrations({
|
||||
Backbone,
|
||||
database: Object.assign(
|
||||
{},
|
||||
database,
|
||||
isString(databaseName) ? { id: databaseName } : {}
|
||||
),
|
||||
});
|
||||
|
||||
exports.getDatabase = () => ({
|
||||
name: database.id,
|
||||
|
||||
Reference in New Issue
Block a user