fix: only run patch for MariaDB (#31891)

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
Akhil Narang 2025-03-25 13:52:33 +05:30 committed by GitHub
parent 49e4220961
commit d1870b745e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2,4 +2,7 @@ import frappe
def execute():
frappe.db.sql("ALTER TABLE __UserSettings CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;")
if frappe.db.db_type == "mariadb":
frappe.db.sql(
"ALTER TABLE __UserSettings CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;"
)