mirror of
https://github.com/processone/ejabberd
synced 2025-10-03 17:59:31 +02:00
Allow a subscribed owner/admin to kick lower-affiliation moderator
This commit is contained in:
parent
49f1b4a691
commit
e054c2800b
1 changed files with 9 additions and 0 deletions
|
@ -3055,11 +3055,20 @@ can_change_ra(owner, moderator, TAffiliation,
|
||||||
moderator, role, none, _ServiceAf)
|
moderator, role, none, _ServiceAf)
|
||||||
when TAffiliation /= owner ->
|
when TAffiliation /= owner ->
|
||||||
true;
|
true;
|
||||||
|
can_change_ra(owner, subscriber, TAffiliation,
|
||||||
|
moderator, role, none, _ServiceAf)
|
||||||
|
when TAffiliation /= owner ->
|
||||||
|
true;
|
||||||
can_change_ra(admin, moderator, TAffiliation,
|
can_change_ra(admin, moderator, TAffiliation,
|
||||||
moderator, role, none, _ServiceAf)
|
moderator, role, none, _ServiceAf)
|
||||||
when (TAffiliation /= owner) and
|
when (TAffiliation /= owner) and
|
||||||
(TAffiliation /= admin) ->
|
(TAffiliation /= admin) ->
|
||||||
true;
|
true;
|
||||||
|
can_change_ra(admin, subscriber, TAffiliation,
|
||||||
|
moderator, role, none, _ServiceAf)
|
||||||
|
when (TAffiliation /= owner) and
|
||||||
|
(TAffiliation /= admin) ->
|
||||||
|
true;
|
||||||
can_change_ra(_FAffiliation, _FRole, _TAffiliation,
|
can_change_ra(_FAffiliation, _FRole, _TAffiliation,
|
||||||
_TRole, role, _Value, _ServiceAf) ->
|
_TRole, role, _Value, _ServiceAf) ->
|
||||||
false.
|
false.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue