Finegrained config of XEP-0095 CSNs for MUCs as well

This commit is contained in:
JC Brand 2019-08-02 12:05:11 +02:00
parent ec85490f1c
commit 5f0a0138a0

View File

@ -742,6 +742,10 @@ converse.plugins.add('converse-muc', {
this.features.get('moderated') && this.getOwnRole() === 'visitor') {
return;
}
const allowed = _converse.send_chat_state_notifications;
if (Array.isArray(allowed) && !allowed.includes(this.get('chat_state'))) {
return;
}
const chat_state = this.get('chat_state');
if (chat_state === _converse.GONE) {
// <gone/> is not applicable within MUC context