Explorar o código

chatview: use `utils.isPersistableModel`

JC Brand %!s(int64=8) %!d(string=hai) anos
pai
achega
3e8e770517
Modificáronse 1 ficheiros con 1 adicións e 3 borrados
  1. 1 3
      src/converse-chatview.js

+ 1 - 3
src/converse-chatview.js

@@ -778,9 +778,7 @@
                 },
 
                 afterShown: function (focus) {
-                    if (this.model.collection.browserStorage) {
-                        // Without a connection, we haven't yet initialized
-                        // localstorage
+                    if (utils.isPersistableModel(this.model)) {
                         this.model.save();
                     }
                     this.setChatState(_converse.ACTIVE);