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
764a7101
Commit
764a7101
authored
Mar 02, 2013
by
ichim-david
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cached presence for onChatRoomPresence and removed length comparision to > 0
parent
300b069a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
converse.js
converse.js
+5
-4
No files found.
converse.js
View file @
764a7101
...
...
@@ -963,12 +963,13 @@
onChatRoomPresence
:
function
(
presence
,
room
)
{
// TODO see if nick is useful
var
nick
=
room
.
nick
,
from
=
$
(
presence
).
attr
(
'
from
'
);
if
(
$
(
presence
).
attr
(
'
type
'
)
!==
'
error
'
)
{
$presence
=
$
(
presence
),
from
=
$presence
.
attr
(
'
from
'
);
if
(
$presence
.
attr
(
'
type
'
)
!==
'
error
'
)
{
// check for status 110 to see if it's our own presence
if
(
$
(
presence
).
find
(
"
status[code='110']
"
).
length
>
0
)
{
if
(
$
presence
.
find
(
"
status[code='110']
"
).
length
)
{
// check if server changed our nick
if
(
$
(
presence
).
find
(
"
status[code='210']
"
).
length
>
0
)
{
if
(
$
presence
.
find
(
"
status[code='210']
"
).
length
)
{
this
.
model
.
set
({
'
nick
'
:
Strophe
.
getResourceFromJid
(
from
)});
}
}
...
...
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