]> granicus.if.org Git - ejabberd/commitdiff
allow get_default on PEP nodes (EJAB-656)
authorChristophe Romain <christophe.romain@process-one.net>
Thu, 19 Jun 2008 09:08:30 +0000 (09:08 +0000)
committerChristophe Romain <christophe.romain@process-one.net>
Thu, 19 Jun 2008 09:08:30 +0000 (09:08 +0000)
SVN Revision: 1363

src/mod_pubsub/mod_pubsub.erl

index 84b9f5e2ea1890a5a7173a0ba3927b6506da78dd..7645d316b0bc721ade42f8537daff8b387fc28f4 100644 (file)
@@ -2342,7 +2342,10 @@ get_configure(Host, Node, From, Lang) ->
     transaction(Host, Node, Action, sync_dirty).
 
 get_default(Host, _Node, _From, Lang) ->
-    Type = hd(plugins(Host)),  % first configured plugin is default
+    Type = case Host of
+    {_, _, _} -> ?PEPNODE;
+    _ -> hd(plugins(Host))
+    end,
     Options = node_options(Type),
     {result, [{xmlelement, "pubsub", [{"xmlns", ?NS_PUBSUB_OWNER}],
                [{xmlelement, "default", [],