Page MenuHomePhabricator

D11249.id37866.diff
No OneTemporary

D11249.id37866.diff

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
@@ -512,6 +512,15 @@
return create_table(db, query, "communities");
}
+bool create_integrity_table(sqlite3 *db) {
+ std::string query =
+ "CREATE TABLE IF NOT EXISTS integrity ("
+ " id TEXT UNIQUE PRIMARY KEY NOT NULL,"
+ " threadHash TEXT NOT NULL"
+ ");";
+ return create_table(db, query, "integrity");
+}
+
bool create_schema(sqlite3 *db) {
char *error;
sqlite3_exec(
@@ -605,6 +614,11 @@
" community_info TEXT NOT NULL"
");"
+ "CREATE TABLE IF NOT EXISTS integrity ("
+ " id TEXT UNIQUE PRIMARY KEY NOT NULL,"
+ " threadHash TEXT NOT NULL"
+ ");"
+
"CREATE INDEX IF NOT EXISTS media_idx_container"
" ON media (container);"
@@ -845,7 +859,8 @@
{32, {create_users_table, true}},
{33, {create_keyservers_table, true}},
{34, {enable_rollback_journal_mode, false}},
- {35, {create_communities_table, true}}}};
+ {35, {create_communities_table, true}},
+ {36, {create_integrity_table, true}}}};
enum class MigrationResult { SUCCESS, FAILURE, NOT_APPLIED };

File Metadata

Mime Type
text/plain
Expires
Tue, Dec 3, 12:02 PM (21 h, 30 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2611607
Default Alt Text
D11249.id37866.diff (1 KB)

Event Timeline