Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
3f0920a8
Commit
3f0920a8
authored
6 years ago
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't remove occupants who are on member lists.
updates #1094
parent
9afc344b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
12 deletions
+8
-12
src/converse-muc.js
src/converse-muc.js
+8
-12
No files found.
src/converse-muc.js
View file @
3f0920a8
...
...
@@ -741,19 +741,15 @@
return
true
;
}
const
occupant
=
this
.
occupants
.
findOccupant
(
data
);
if
(
data
.
type
===
'
unavailable
'
)
{
if
(
occupant
)
{
// Even before destroying, we set the new data, so
// that we can for example show the
// disconnection message.
if
(
data
.
type
===
'
unavailable
'
&&
occupant
)
{
if
(
!
_
.
includes
(
data
.
states
,
converse
.
MUC_NICK_CHANGED_CODE
)
&&
!
_
.
includes
([
'
admin
'
,
'
owner
'
,
'
member
'
],
occupant
.
get
(
'
affiliation
'
)))
{
// We only destroy the occupant if this is not a nickname change operation.
// and if they're not on the member lists.
// Before destroying we set the new data, so
// that we can show the disconnection message.
occupant
.
set
(
data
);
}
if
(
!
_
.
includes
(
data
.
states
,
converse
.
MUC_NICK_CHANGED_CODE
))
{
// We only destroy the occupant if this is not a
// nickname change operation.
if
(
occupant
)
{
occupant
.
destroy
();
}
occupant
.
destroy
();
return
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment