mirror of
https://github.com/processone/ejabberd.git
synced 2024-12-22 17:28:25 +01:00
fix delete-items issue and manage-affiliations typo
SVN Revision: 1868
This commit is contained in:
parent
ec31aef6cb
commit
bb13c9e8ab
@ -1584,7 +1584,7 @@ delete_item(Host, Node, Publisher, ItemId, ForceNotify) ->
|
||||
Action = fun(#pubsub_node{type = Type}) ->
|
||||
Features = features(Type),
|
||||
PersistentFeature = lists:member("persistent-items", Features),
|
||||
DeleteFeature = lists:member("delete-any", Features),
|
||||
DeleteFeature = lists:member("delete-items", Features),
|
||||
if
|
||||
%%-> iq_pubsub just does that matchs
|
||||
%% %% Request does not specify an item
|
||||
@ -1594,7 +1594,7 @@ delete_item(Host, Node, Publisher, ItemId, ForceNotify) ->
|
||||
{error, extended_error(?ERR_FEATURE_NOT_IMPLEMENTED, unsupported, "persistent-items")};
|
||||
not DeleteFeature ->
|
||||
%% Service does not support item deletion
|
||||
{error, extended_error(?ERR_FEATURE_NOT_IMPLEMENTED, unsupported, "delete-any")};
|
||||
{error, extended_error(?ERR_FEATURE_NOT_IMPLEMENTED, unsupported, "delete-items")};
|
||||
true ->
|
||||
node_call(Type, delete_item, [Host, Node, Publisher, ItemId])
|
||||
end
|
||||
@ -1987,7 +1987,7 @@ get_subscriptions(Host, Node, JID) ->
|
||||
if
|
||||
not RetrieveFeature ->
|
||||
%% Service does not support manage subscriptions
|
||||
{error, extended_error(?ERR_FEATURE_NOT_IMPLEMENTED, unsupported, "manage-affiliations")};
|
||||
{error, extended_error(?ERR_FEATURE_NOT_IMPLEMENTED, unsupported, "manage-subscriptions")};
|
||||
Affiliation /= {result, owner} ->
|
||||
%% Entity is not an owner
|
||||
{error, ?ERR_FORBIDDEN};
|
||||
@ -2693,7 +2693,7 @@ features() ->
|
||||
"config-node", % RECOMMENDED
|
||||
"create-and-configure", % RECOMMENDED
|
||||
% see plugin "create-nodes", % RECOMMENDED
|
||||
% see plugin "delete-any", % RECOMMENDED
|
||||
% see plugin "delete-items", % RECOMMENDED
|
||||
% see plugin "delete-nodes", % RECOMMENDED
|
||||
% see plugin "filtered-notifications", % RECOMMENDED
|
||||
%TODO "get-pending", % OPTIONAL
|
||||
|
@ -95,7 +95,7 @@ options() ->
|
||||
features() ->
|
||||
["create-nodes",
|
||||
"delete-nodes",
|
||||
"delete-any",
|
||||
"delete-items",
|
||||
"instant-nodes",
|
||||
"outcast-affiliation",
|
||||
"persistent-items",
|
||||
|
@ -97,7 +97,7 @@ options() ->
|
||||
features() ->
|
||||
["create-nodes",
|
||||
"delete-nodes",
|
||||
"delete-any",
|
||||
"delete-items",
|
||||
"instant-nodes",
|
||||
"item-ids",
|
||||
"outcast-affiliation",
|
||||
|
@ -97,7 +97,7 @@ options() ->
|
||||
features() ->
|
||||
["create-nodes",
|
||||
"delete-nodes",
|
||||
"delete-any",
|
||||
"delete-items",
|
||||
"instant-nodes",
|
||||
"outcast-affiliation",
|
||||
"persistent-items",
|
||||
|
@ -159,7 +159,7 @@ features() ->
|
||||
["create-nodes",
|
||||
"auto-create",
|
||||
"delete-nodes",
|
||||
"delete-any",
|
||||
"delete-items",
|
||||
"instant-nodes",
|
||||
"manage-subscriptions",
|
||||
"modify-affiliations",
|
||||
|
@ -102,7 +102,7 @@ features() ->
|
||||
"auto-create", %*
|
||||
"auto-subscribe", %*
|
||||
"delete-nodes", %*
|
||||
"delete-any", %*
|
||||
"delete-items", %*
|
||||
"filtered-notifications", %*
|
||||
"modify-affiliations",
|
||||
"outcast-affiliation",
|
||||
|
@ -97,7 +97,7 @@ features() ->
|
||||
"auto-create", %*
|
||||
"auto-subscribe", %*
|
||||
"delete-nodes", %*
|
||||
"delete-any", %*
|
||||
"delete-items", %*
|
||||
"filtered-notifications", %*
|
||||
"modify-affiliations",
|
||||
"outcast-affiliation",
|
||||
|
@ -97,7 +97,7 @@ options() ->
|
||||
features() ->
|
||||
["create-nodes",
|
||||
"delete-nodes",
|
||||
"delete-any",
|
||||
"delete-items",
|
||||
"instant-nodes",
|
||||
"outcast-affiliation",
|
||||
"persistent-items",
|
||||
|
@ -97,7 +97,7 @@ options() ->
|
||||
features() ->
|
||||
["create-nodes",
|
||||
"delete-nodes",
|
||||
"delete-any",
|
||||
"delete-items",
|
||||
"instant-nodes",
|
||||
"outcast-affiliation",
|
||||
"persistent-items",
|
||||
|
Loading…
Reference in New Issue
Block a user