0
0
Fork 1
mirror of https://mau.dev/maunium/synapse.git synced 2024-12-15 05:33:53 +01:00

Use case sensitive collations

This commit is contained in:
Erik Johnston 2015-04-10 18:46:33 +01:00
parent 4103b1c470
commit c5365dee56
2 changed files with 2 additions and 3 deletions

View file

@ -363,7 +363,6 @@ def setup(config_options):
db_config = {
k: v for k, v in db_config.items()
if not k.startswith("cp_")
}
name = db_config.get("name", None)
@ -372,7 +371,7 @@ def setup(config_options):
"sql_mode": "TRADITIONAL",
"charset": "utf8mb4",
"use_unicode": True,
"collation": "utf8mb4_general_ci",
"collation": "utf8mb4_bin",
})
elif name == "sqlite3":
db_config.setdefault("args", {}).update({

View file

@ -36,7 +36,7 @@ class MariaEngine(object):
def prepare_database(self, db_conn):
cur = db_conn.cursor()
cur.execute(
"ALTER DATABASE CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci"
"ALTER DATABASE CHARACTER SET utf8mb4 COLLATE utf8mb4_bin"
)
db_conn.commit()
prepare_database(db_conn, self)