Преглед изворни кода

Better check to know whether we can save the model

JC Brand пре 8 година
родитељ
комит
fcbeff4c72
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      src/converse-chatview.js

+ 1 - 1
src/converse-chatview.js

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