index.js
function allowed(packet) {
    if (!packet) return false;

    if (uv.position === 'inactive' || (!uv.received(packet.id) && ordered)) {
      queue.push(packet);
      return false;
    }

    return true;
  }
function allowed(packet) {
    if (!packet) return false;

    if (uv.position === 'inactive' || (!uv.received(packet.id) && ordered)) {
      queue.push(packet);
      return false;
    }

    return true;
  }
function allowed ( packet ) { if ( ! packet ) return false ; if ( uv . position === 'inactive' || ( ! uv . received ( packet . id ) && ordered ) ) { queue . push ( packet ) ; return false ; } return true ; }
Checks if we are allowed to emit the message.

@param {Object} packet The message packet.
@api private
Checks if we are allowed to emit the message .