Browse Source

Bugfix. Check if from exists

JC Brand 12 năm trước cách đây
mục cha
commit
7a46e0ed73
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      Libraries/strophe.muc.js

+ 1 - 0
Libraries/strophe.muc.js

@@ -75,6 +75,7 @@
                 this._muc_handler = this._connection.addHandler(function(stanza) {
                     var from, handler, handlers, id, roomname, x, xmlns, xquery, _i, _len;
                     from = stanza.getAttribute('from');
+                    if (!from) { return true; }
                     roomname = from.split("/")[0];
                     if (!_this.rooms[roomname]) { return true; }
                     room = _this.rooms[roomname];