From e6535dcc67d25ddbd7bab3824f9018243e1e05b5 Mon Sep 17 00:00:00 2001 From: Christophe Romain Date: Thu, 18 Dec 2008 13:46:30 +0000 Subject: [PATCH] Check option of the nodetree instead of checking configuration SVN Revision: 1738 --- ChangeLog | 5 +++++ src/mod_pubsub/mod_pubsub.erl | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index a7667f87e..baa889ee2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-12-18 Christophe Romain + + * src/mod_pubsub/mod_pubsub.erl: Check option of the nodetree instead + of checking configuration (thanks to Eric Cestari)(EJAB-737) + 2008-12-17 Pablo Polvorin * src/mod_muc/mod_muc_room.erl: Fix bug in MUC invite. diff --git a/src/mod_pubsub/mod_pubsub.erl b/src/mod_pubsub/mod_pubsub.erl index 48d2ca061..0440f24b3 100644 --- a/src/mod_pubsub/mod_pubsub.erl +++ b/src/mod_pubsub/mod_pubsub.erl @@ -1244,8 +1244,8 @@ create_node(Host, ServerHost, Node, Owner, GivenType, Access, Configuration) -> ok -> node_call(Type, create_node, [Host, Node, Owner]); {error, 'conflict'} -> - case ets:lookup(gen_mod:get_module_proc(ServerHost, pubsub_state), nodetree) of - [{nodetree, nodetree_virtual}] -> node_call(Type, create_node, [Host, Node, Owner]); + case proplists:get_value(virtual_tree, tree_call(Host, options, [])) of + true -> node_call(Type, create_node, [Host, Node, Owner]); _ -> {error, 'conflict'} end; Error ->