diff --git a/native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.cpp b/native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.cpp --- a/native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.cpp +++ b/native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.cpp @@ -531,6 +531,15 @@ return create_table(db, query, "messages_to_device"); } +bool create_integrity_table(sqlite3 *db) { + std::string query = + "CREATE TABLE IF NOT EXISTS integrity_store (" + " id TEXT UNIQUE PRIMARY KEY NOT NULL," + " thread_hash TEXT NOT NULL" + ");"; + return create_table(db, query, "integrity_store"); +} + bool create_schema(sqlite3 *db) { char *error; sqlite3_exec( @@ -634,6 +643,11 @@ " PRIMARY KEY (message_id, device_id)" ");" + "CREATE TABLE IF NOT EXISTS integrity_store (" + " id TEXT UNIQUE PRIMARY KEY NOT NULL," + " thread_hash TEXT NOT NULL" + ");" + "CREATE INDEX IF NOT EXISTS media_idx_container" " ON media (container);" @@ -879,7 +893,8 @@ {33, {create_keyservers_table, true}}, {34, {enable_rollback_journal_mode, false}}, {35, {create_communities_table, true}}, - {36, {create_messages_to_device_table, true}}}}; + {36, {create_messages_to_device_table, true}}, + {37, {create_integrity_table, true}}}}; enum class MigrationResult { SUCCESS, FAILURE, NOT_APPLIED }; diff --git a/web/shared-worker/_generated/comm_query_executor.wasm b/web/shared-worker/_generated/comm_query_executor.wasm index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 GIT binary patch literal 0 Hc$@