code: function _removeIdle() {
      var removals = [];
      var now = Date.now();
  
      this._removeIdleScheduled = false;
  
      // Go through the available (idle) items, check if they have timed out
      var minCount = this._count - this._opts.min;
      var refreshIdle = this._opts.refreshIdle;
      for (
          var i = 0;
          i < this._availableObjects.length && (refreshIdle || (minCount > removals.length));
          ++i
      ) {
          var timeout = this._availableObjects[i].timeout;
          if (now >= timeout) {
              // Client timed out, so destroy it.
              this._log(
                  'removeIdle() destroying obj - now:' + now + ' timeout:' + timeout,
                  'verbose'
              );
              removals.push(this.destroy(this._availableObjects[i].obj));
              --i;
          }
      }
  
      // Replace the available items with the ones to keep.
      if (this._availableObjects.length > 0) {
          this._log('availableObjects.length=' + this._availableObjects.length, 'verbose');
          _scheduleRemoveIdle.call(this);
      }
      else {
          this._log('removeIdle() all objects removed', 'verbose');
      }
  
      // Return a promise for when all the destructions have completed.
      return Promise.all(removals);
  }
docs: Checks and removes the available (idle) clients that have timed out.
  
  @private
  @this {PromisePool}
  
  @return {Promise} A promise for when all idle connections have been removed.