mirror of
https://github.com/processone/ejabberd.git
synced 2024-09-27 14:30:55 +02:00
Try to update SQL schema only on supported RDBMS
This commit is contained in:
parent
f2552faca8
commit
7309f9f88a
@ -658,7 +658,14 @@ create_tables(Host, Module, Schema) ->
|
||||
store_version(Host, Module, Schema#sql_schema.version).
|
||||
|
||||
should_update_schema(Host) ->
|
||||
case ejabberd_option:update_sql_schema() of
|
||||
SupportedDB =
|
||||
case ejabberd_option:sql_type(Host) of
|
||||
pgsql -> true;
|
||||
sqlite -> true;
|
||||
mysql -> true;
|
||||
_ -> false
|
||||
end,
|
||||
case ejabberd_option:update_sql_schema() andalso SupportedDB of
|
||||
true ->
|
||||
case ejabberd_sql:use_new_schema() of
|
||||
true ->
|
||||
|
Loading…
Reference in New Issue
Block a user