signal-desktop/ts/sql/migrations/940-fts5-revert.ts

26 lines
595 B
TypeScript
Raw Normal View History

2023-09-02 23:03:19 +00:00
// Copyright 2023 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
import type { Database } from '@signalapp/better-sqlite3';
import type { LoggerType } from '../../types/Logging';
export const version = 940;
export function updateToSchemaVersion940(
currentVersion: number,
db: Database,
logger: LoggerType
): void {
if (currentVersion >= 940) {
return;
}
db.transaction(() => {
2023-10-10 23:55:32 +00:00
// This was a migration that disabled secure-delete and rebuilt the index
2023-09-02 23:03:19 +00:00
db.pragma('user_version = 940');
})();
logger.info('updateToSchemaVersion940: success!');
}