pubsub_migrate:update_node_database(Host, ServerHost),
pubsub_migrate:update_state_database(Host, ServerHost),
pubsub_migrate:update_lastitem_database(Host, ServerHost),
- init_nodes(Host, ServerHost, NodeTree, Plugins),
{_, State} = init_send_loop(ServerHost),
{ok, State}.
TreePlugin:terminate(Host, ServerHost),
ok.
-init_nodes(Host, ServerHost, _NodeTree, Plugins) ->
- case lists:member(<<"hometree">>, Plugins) of
- true ->
- create_node(Host, ServerHost, <<"/home">>, service_jid(Host), <<"hometree">>),
- create_node(Host, ServerHost, <<"/home/", ServerHost/binary>>, service_jid(Host), <<"hometree">>);
- false -> ok
- end.
-
send_loop(State) ->
receive
{presence, JID, Pid} ->