25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-28 16:34:13 +01:00

make sure caps table are clean on startup

SVN Revision: 2013
This commit is contained in:
Christophe Romain 2009-04-10 08:01:08 +00:00
parent 409ab48068
commit 549fa6e836

View File

@ -213,6 +213,8 @@ init([Host, _Opts]) ->
{type, bag}, {type, bag},
{attributes, record_info(fields, user_caps_resources)}]), {attributes, record_info(fields, user_caps_resources)}]),
mnesia:delete_table(user_caps_default), mnesia:delete_table(user_caps_default),
mnesia:clear_table(user_caps),
mnesia:clear_table(user_caps_resources),
ejabberd_hooks:add(user_receive_packet, Host, ?MODULE, receive_packet, 30), ejabberd_hooks:add(user_receive_packet, Host, ?MODULE, receive_packet, 30),
ejabberd_hooks:add(s2s_receive_packet, Host, ?MODULE, receive_packet, 30), ejabberd_hooks:add(s2s_receive_packet, Host, ?MODULE, receive_packet, 30),
{ok, #state{host = Host}}. {ok, #state{host = Host}}.