mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2024-10-01 08:25:44 -04:00
Merge pull request #633 from matrix-org/daniel/ick
Idempotent-ise schema update script
This commit is contained in:
commit
b117f67227
@ -20,7 +20,11 @@ logger = logging.getLogger(__name__)
|
||||
|
||||
def run_upgrade(cur, database_engine, config, *args, **kwargs):
|
||||
# NULL indicates user was not registered by an appservice.
|
||||
cur.execute("ALTER TABLE users ADD COLUMN appservice_id TEXT")
|
||||
try:
|
||||
cur.execute("ALTER TABLE users ADD COLUMN appservice_id TEXT")
|
||||
except:
|
||||
# Maybe we already added the column? Hope so...
|
||||
pass
|
||||
|
||||
cur.execute("SELECT name FROM users")
|
||||
rows = cur.fetchall()
|
||||
|
Loading…
Reference in New Issue
Block a user