lib/SlaveArray.js
/**
   * @return {Array<Object>} An array of all the socket.io instances for each slave in the array.
   * An additional "on" function allows you to attach a socket.on(.*) listener to all the sockets.
   */
@return {Array} An array of all the socket.io instances for each slave in the array.
An additional "on" function allows you to attach a socket.on(.*) listener to all the sockets.
@return { Array } An array of all the socket . io instances for each slave in the array . An additional " on " function allows you to attach a socket . on ( . * ) listener to all the sockets .
get sockets() {
    const sockets = [];
    this.forEach(slave => {
      if (slave.isRemote) sockets.push(slave.socket);
    });
    Object.defineProperty(sockets, 'on', {
      configurable: true,
      enumerable: false,
      writable: true,
      value: (event, handler) => sockets.forEach(socket => socket.on(event, handler)),
    });
    return sockets;
  }
get sockets ( ) { const sockets = [ ] ; this . forEach ( slave => { if ( slave . isRemote ) sockets . push ( slave . socket ) ; } ) ; Object . defineProperty ( sockets , 'on' , { configurable : true , enumerable : false , writable : true , value : ( event , handler ) => sockets . forEach ( socket => socket . on ( event , handler ) ) , } ) ; return sockets ; }
@return {Array<Object>} An array of all the socket.io instances for each slave in the array.
@return { Array<Object > } An array of all the socket . io instances for each slave in the array .