fix: can't compare str with int
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
parent
61e54eac17
commit
06db7a2b2b
1 changed files with 1 additions and 1 deletions
|
|
@ -21,7 +21,7 @@ def setup_database():
|
|||
root_conn.sql(f'GRANT ALL PRIVILEGES ON DATABASE "{frappe.conf.db_name}" TO "{frappe.conf.db_user}"')
|
||||
if psql_version := root_conn.sql("SHOW server_version_num", as_dict=True):
|
||||
semver_version_num = psql_version[0].get("server_version_num") or "140000"
|
||||
if semver_version_num > 150000:
|
||||
if cint(semver_version_num) > 150000:
|
||||
root_conn.sql(f'ALTER DATABASE "{frappe.conf.db_name}" OWNER TO "{frappe.conf.db_user}"')
|
||||
root_conn.close()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue