Skip to content

wayback provider doesn't await mergeOptions #6

@oritwoen

Description

@oritwoen

In src/providers/wayback.ts:32, mergeOptions returns a Promise<T> but the result isn't awaited:

const options = mergeOptions(initOptions, reqOptions)

Later the code does await options inline (lines 47 and 64), which works but means options is a Promise being passed around instead of the resolved value. Every other provider awaits it at the call site:

  • commoncrawl.ts:33const options = await mergeOptions(...)
  • archive-today.ts:27const options = await mergeOptions(...)
  • permacc.ts:28const options = await mergeOptions(...)
  • webcite.ts:35const options = await mergeOptions(...)

The fix is just adding await on line 32 and removing the await wrappers on lines 47/64.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions