Avoid background thread overwriting outgoing messages
This commit is contained in:
parent
d7edfd4efb
commit
7a6c15bb32
1 changed files with 2 additions and 0 deletions
|
@ -70,6 +70,8 @@ extend(Backbone.LocalStorage.prototype, {
|
||||||
|
|
||||||
// Save the current state of the **Store** to *localStorage*.
|
// Save the current state of the **Store** to *localStorage*.
|
||||||
save: function() {
|
save: function() {
|
||||||
|
var store = this.localStorage().getItem(this.name);
|
||||||
|
this.records = _.union(this.records, store && store.split(","));
|
||||||
this.localStorage().setItem(this.name, this.records.join(","));
|
this.localStorage().setItem(this.name, this.records.join(","));
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue