mirror of
https://github.com/moparisthebest/kaiwa
synced 2024-11-25 10:42:17 -05:00
Refresh roster cache correctly (anytime there's a roster result with items).
This commit is contained in:
parent
6f1a7b7056
commit
9dc5757e9b
@ -114,8 +114,7 @@ module.exports = function (client, app) {
|
|||||||
client.getRoster(function (err, resp) {
|
client.getRoster(function (err, resp) {
|
||||||
resp = resp.toJSON();
|
resp = resp.toJSON();
|
||||||
|
|
||||||
var resultVer = resp.roster.ver;
|
if (resp.roster && resp.roster.items && resp.roster.items.length) {
|
||||||
if (me.rosterVer && resultVer && me.rosterVer !== resultVer) {
|
|
||||||
app.storage.roster.clear(function () {
|
app.storage.roster.clear(function () {
|
||||||
me.contacts.reset();
|
me.contacts.reset();
|
||||||
me.rosterVer = resp.roster.ver;
|
me.rosterVer = resp.roster.ver;
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "otalk.im",
|
"name": "otalk.im",
|
||||||
"version": "0.0.23",
|
"version": "0.0.24",
|
||||||
"description": "Otalk: WebRTC Enabled XMPP Client, in the Browser",
|
"description": "Otalk: WebRTC Enabled XMPP Client, in the Browser",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
Loading…
Reference in New Issue
Block a user