mirror of
https://github.com/processone/ejabberd.git
synced 2024-12-20 17:27:00 +01:00
Don't produce a crash on config reload when SQL is not configured
This commit is contained in:
parent
7e8bd484d5
commit
1b0d481f41
@ -98,7 +98,10 @@ stop_host(Host) ->
|
|||||||
|
|
||||||
-spec reload_host(binary()) -> ok.
|
-spec reload_host(binary()) -> ok.
|
||||||
reload_host(Host) ->
|
reload_host(Host) ->
|
||||||
ejabberd_sql_sup:reload(Host).
|
case needs_sql(Host) of
|
||||||
|
true -> ejabberd_sql_sup:reload(Host);
|
||||||
|
false -> ok
|
||||||
|
end.
|
||||||
|
|
||||||
%% Returns {true, App} if we have configured sql for the given host
|
%% Returns {true, App} if we have configured sql for the given host
|
||||||
needs_sql(Host) ->
|
needs_sql(Host) ->
|
||||||
|
Loading…
Reference in New Issue
Block a user