mirror of
https://github.com/processone/ejabberd.git
synced 2024-09-29 14:37:44 +02:00
Fix compatibility with OTP < 23 in ejabberd_sql_schema
This commit is contained in:
parent
dbbbd49522
commit
9264f2bcdd
@ -200,7 +200,7 @@ find_index_name(Host, Table, Columns) ->
|
|||||||
end.
|
end.
|
||||||
|
|
||||||
get_version(Host, Module) ->
|
get_version(Host, Module) ->
|
||||||
SModule = atom_to_binary(Module),
|
SModule = misc:atom_to_binary(Module),
|
||||||
ejabberd_sql:sql_query(
|
ejabberd_sql:sql_query(
|
||||||
Host,
|
Host,
|
||||||
?SQL("select @(version)d"
|
?SQL("select @(version)d"
|
||||||
@ -208,7 +208,7 @@ get_version(Host, Module) ->
|
|||||||
" where module=%(SModule)s")).
|
" where module=%(SModule)s")).
|
||||||
|
|
||||||
store_version(Host, Module, Version) ->
|
store_version(Host, Module, Version) ->
|
||||||
SModule = atom_to_binary(Module),
|
SModule = misc:atom_to_binary(Module),
|
||||||
?SQL_UPSERT(
|
?SQL_UPSERT(
|
||||||
Host,
|
Host,
|
||||||
"schema_version",
|
"schema_version",
|
||||||
|
Loading…
Reference in New Issue
Block a user