Commit f0f7cfab authored by JC Brand's avatar JC Brand

Make the chatbox messages cache key overridable

parent 5b64b5a0
......@@ -295,10 +295,13 @@ converse.plugins.add('converse-chatboxes', {
this.fetchMessages();
},
getMessagesCacheKey () {
return `converse.messages-${this.get('jid')}-${_converse.bare_jid}`;
},
initMessages () {
this.messages = new this.messagesCollection();
this.messages.browserStorage = new BrowserStorage.session(
`converse.messages-${this.get('jid')}-${_converse.bare_jid}`);
this.messages.browserStorage = new BrowserStorage.session(this.getMessagesCacheKey());
this.messages.chatbox = this;
this.messages.on('change:upload', (message) => {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment