aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Romain <chris.romain@gmail.com>2010-06-02 14:37:18 +0200
committerChristophe Romain <chris.romain@gmail.com>2010-06-02 14:37:18 +0200
commitd56522c8a0bf55abef44215fea80d327b8bcd6b6 (patch)
tree668bfeb3bc66bbbf9e5063c9810ce6b2e805e41e
parentUpdate the Norwegian translation (thanks to Stian B. Barmen) (diff)
final fix on created node notification (EJAB-1225)
-rw-r--r--src/mod_pubsub/mod_pubsub.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mod_pubsub/mod_pubsub.erl b/src/mod_pubsub/mod_pubsub.erl
index 0e0491863..01c295a8b 100644
--- a/src/mod_pubsub/mod_pubsub.erl
+++ b/src/mod_pubsub/mod_pubsub.erl
@@ -1734,17 +1734,17 @@ create_node(Host, ServerHost, Node, Owner, GivenType, Access, Configuration) ->
end,
case node_call(Type, create_node_permission, [Host, ServerHost, Node, Parent, Owner, Access]) of
{result, true} ->
- ParentTree = tree_call(Host, get_parentnodes_tree, [Host, Node, Owner]),
- SubsByDepth = [{Depth, [{N, get_node_subs(N)} || N <- Nodes]} || {Depth, Nodes} <- ParentTree],
case tree_call(Host, create_node, [Host, Node, Type, Owner, NodeOptions, Parents]) of
{ok, NodeId} ->
+ ParentTree = tree_call(Host, get_parentnodes_tree, [Host, Node, Owner]),
+ SubsByDepth = [{Depth, [{N, get_node_subs(N)} || N <- Nodes]} || {Depth, Nodes} <- ParentTree],
case node_call(Type, create_node, [NodeId, Owner]) of
{result, Result} -> {result, {NodeId, SubsByDepth, Result}};
Error -> Error
end;
{error, {virtual, NodeId}} ->
case node_call(Type, create_node, [NodeId, Owner]) of
- {result, Result} -> {result, {NodeId, SubsByDepth, Result}};
+ {result, Result} -> {result, {NodeId, [], Result}};
Error -> Error
end;
Error ->