Emptying the resources array when the resource is null
This commit is contained in:
rlanvin 2016-01-19 13:52:04 +02:00
parent 226e2e910d
commit 8d495d30fe
2 changed files with 8 additions and 0 deletions

7
converse.js Normal file → Executable file
View File

@ -4192,6 +4192,13 @@
this.save({'resources': resources});
}
}
else {
// if there is no resource (resource is null), it probably
// means that the user is now completely offline. To make sure
// that there isn't any "ghost" resources left, we empty the array
this.save({'resources': []});
return 0;
}
return resources.length;
},

1
docs/CHANGES.md Normal file → Executable file
View File

@ -15,6 +15,7 @@
- #547 By default the `offline` state is no longer choosable.
See [include_offline_state](https://conversejs.org/docs/html/configuration.html#include_offline_state) for details. [jcbrand]
- A chatroom invite might come from someone not in your roster list. [ben]
- #487 Empty the resources array when the resource is null [rlanvin]
## 0.10.0 (2015-11-05)