docs: function(dialogIdOrJid, callback) {
          /**
           * Callback for QB.chat.muc.join().
           * @param {Object} error - Returns error object or null
           * @param {Object} responce - Returns responce
           * @callback joinMacCallback
           * */
          var self = this,
              id = chatUtils.getUniqueId('join');
  
          var dialogJid = this.helpers.getDialogJid(dialogIdOrJid);
  
          var presParams = {
                  id: id,
                  from: self.helpers.getUserCurrentJid(),
                  to: self.helpers.getRoomJid(dialogJid)
              },
              builder = Utils.getEnv().browser ? $pres : XMPP.Stanza;
  
          var pres = chatUtils.createStanza(builder, presParams, 'presence');
  
          pres.c('x', {
              xmlns: chatUtils.MARKERS.MUC
          }).c('history', { maxstanzas: 0 });
  
          this.joinedRooms[dialogJid] = true;
  
          function handleJoinAnswer(stanza) {
              var id = chatUtils.getAttr(stanza, 'id');
              var from = chatUtils.getAttr(stanza, 'from');
              var dialogId = self.helpers.getDialogIdFromNode(from);
              
              var x = chatUtils.getElement(stanza, 'x');
              var xXMLNS = chatUtils.getAttr(x, 'xmlns');
              var status = chatUtils.getElement(x, 'status');
              var statusCode = chatUtils.getAttr(status, 'code');
  
              if (callback.length == 1) {
                  Utils.safeCallbackCall(callback, stanza);
                  return true;
              }
  
              if(status && statusCode == '110') {
                  Utils.safeCallbackCall(callback, null, {
                      dialogId: dialogId
                  });
              } else {
                  var type = chatUtils.getAttr(stanza, 'type');
  
                  if(type && type === 'error' && xXMLNS == 'http://jabber.org/protocol/muc' && id.endsWith(':join')) {
                      var errorEl = chatUtils.getElement(stanza, 'error');
                      var code = chatUtils.getAttr(errorEl, 'code');
                      var errorMessage = chatUtils.getElementText(errorEl, 'text');
      
                      Utils.safeCallbackCall(callback, {
                          code: code || 500,
                          message: errorMessage || 'Unknown issue'
                      }, {
                          dialogId: dialogId
                      });
                  }
              }
          }
  
          if (Utils.getEnv().browser) {
              if (typeof callback === 'function') {
                  self.connection.XAddTrackedHandler(handleJoinAnswer, null, 'presence', null, id);
              }
  
              self.connection.send(pres);
          } else {
              if (typeof callback === 'function') {
                  self.nodeStanzasCallbacks[id] = handleJoinAnswer;
              }
  
              self.Client.send(pres);
          }
      }