feat: add bot field to contact (#4821)

closes #4647
This commit is contained in:
Sebastian Klähn
2023-10-15 12:40:32 +02:00
committed by link2xt
parent ac557f73b3
commit e725bdfb2b
5 changed files with 43 additions and 1 deletions

View File

@@ -740,6 +740,15 @@ CREATE INDEX smtp_messageid ON imap(rfc724_mid);
.await?;
}
// Add is_bot column to contacts table with default false.
if dbversion < 103 {
sql.execute_migration(
"ALTER TABLE contacts ADD COLUMN is_bot INTEGER NOT NULL DEFAULT 0",
103,
)
.await?;
}
let new_version = sql
.get_raw_config_int(VERSION_CFG)
.await?