25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-26 17:38:45 +01:00

Include shared groups also when contact is is personal roster (#1585)

This commit is contained in:
Badlop 2017-03-09 19:21:45 +01:00
parent 7e2380ab0c
commit ee849338dd
2 changed files with 6 additions and 2 deletions

View File

@ -166,10 +166,12 @@ get_user_roster(Items, US) ->
case dict:find(US1, case dict:find(US1,
SRUsers1) SRUsers1)
of of
{ok, _GroupNames} -> {ok, GroupNames} ->
{Item#roster{subscription {Item#roster{subscription
= =
both, both,
groups =
Item#roster.groups ++ GroupNames,
ask = ask =
none}, none},
dict:erase(US1, dict:erase(US1,

View File

@ -113,10 +113,12 @@ get_user_roster(Items, {U, S} = US) ->
case dict:find(US1, case dict:find(US1,
SRUsers1) SRUsers1)
of of
{ok, _GroupNames} -> {ok, GroupNames} ->
{Item#roster{subscription {Item#roster{subscription
= =
both, both,
groups =
Item#roster.groups ++ GroupNames,
ask = ask =
none}, none},
dict:erase(US1, dict:erase(US1,