function onerror(error) {
      cleanup()

      if (!emitter.listenerCount('error')) {
        throw error // Unhandled stream error in pipe.
      }
    }
Close dangling pipes and handle unheard errors.

@param {Error | null | undefined} [error]
  Error, if any.
@returns {undefined}
  Nothing.