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
09c55ebc
Commit
09c55ebc
authored
May 04, 2018
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove the `use_vcards` settings
VCards will now always be used.
parent
6ac1df43
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
24 deletions
+7
-24
CHANGES.md
CHANGES.md
+1
-0
docs/source/configuration.rst
docs/source/configuration.rst
+0
-9
src/converse-vcard.js
src/converse-vcard.js
+6
-15
No files found.
CHANGES.md
View file @
09c55ebc
...
...
@@ -24,6 +24,7 @@
## Configuration changes
-
Removed the
`use_vcards`
configuration setting, instead VCards are always used.
-
Removed the
`xhr_custom_status`
and
`xhr_custom_status_url`
configuration
settings. If you relied on these settings, you can instead listen for the
[
statusMessageChanged
](
https://conversejs.org/docs/html/events.html#contactstatusmessagechanged
)
...
...
docs/source/configuration.rst
View file @
09c55ebc
...
...
@@ -1371,15 +1371,6 @@ use_otr_by_default
If set to ``true``, Converse.js will automatically try to initiate an OTR (off-the-record)
encrypted chat session every time you open a chatbox.
use_vcards
----------
* Default: ``true``
Determines whether the XMPP server will be queried for roster contacts' VCards
or not. VCards contain extra personal information such as your fullname and
avatar image.
visible_toolbar_buttons
-----------------------
...
...
src/converse-vcard.js
View file @
09c55ebc
...
...
@@ -52,26 +52,17 @@
*/
const
to
=
Strophe
.
getBareJidFromJid
(
jid
)
===
_converse
.
bare_jid
?
null
:
jid
;
return
new
Promise
((
resolve
,
reject
)
=>
{
if
(
!
_converse
.
use_vcards
)
{
if
(
resolve
)
{
resolve
({
'
jid
'
:
jid
});
}
}
else
{
_converse
.
connection
.
vcard
.
get
(
_
.
partial
(
onVCardData
,
_converse
,
jid
,
_
,
resolve
),
to
,
_
.
partial
(
onVCardError
,
_converse
,
jid
,
_
,
resolve
)
);
}
});
}
converse
.
plugins
.
add
(
'
converse-vcard
'
,
{
enabled
(
_converse
)
{
_converse
.
api
.
settings
.
update
({
'
use_vcards
'
:
true
});
return
_converse
.
use_vcards
;
},
overrides
:
{
// Overrides mentioned here will be picked up by converse.js's
// plugin architecture they will replace existing methods on the
...
...
@@ -106,7 +97,7 @@
model
:
_converse
.
ModelWithDefaultAvatar
,
initialize
()
{
this
.
on
(
'
add
'
,
(
model
)
=>
_converse
.
api
.
vcard
.
update
(
model
));
this
.
on
(
'
add
'
,
(
vcard
)
=>
_converse
.
api
.
vcard
.
update
(
vcard
));
}
});
...
...
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