hunk.code_window:   if (options.optional) {
       skippedOptionalDependencyLogger.debug({
         details: warn,
         package: {
           id: pkgId,
           name: pkg.name,
           version: pkg.version,
  
hunk.labels: keep keep keep replace keep keep keep keep
hunk.after_edit:       details: warn.toString(),
  
hunk.file_path: src/install/getIsInstallable.ts
hunk.type: replace
file: import {streamParser} from '@pnpm/logger'
  import {StoreController} from 'package-store'
  import {ReporterFunction} from '../types'
  
  export default async function (
    opts: {
      reporter?: ReporterFunction,
      storeController: StoreController,
    },
  ) {
    const reporter = opts && opts.reporter
    if (reporter) {
      streamParser.on('data', reporter)
    }
    await opts.storeController.prune()
    await opts.storeController.saveState()
    await opts.storeController.close()
  
    if (reporter) {
      streamParser.removeListener('data', reporter)
    }
  }
  