Skip to content

Commit

Permalink
Return unmodified request on cancel
Browse files Browse the repository at this point in the history
  • Loading branch information
aaroncox committed Sep 8, 2023
1 parent 940afa3 commit 8f7c5fc
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -341,9 +341,7 @@ export class TransactPluginResourceProvider extends AbstractTransactPlugin {
throw e
}
// Otherwise if it wasn't a cancel, it was a reject, and continue without modification
return new Promise((r) =>
r({request: modifiedRequest})
) as Promise<TransactHookResponse>
return new Promise((r) => r({request})) as Promise<TransactHookResponse>
})
.finally(() => {
clearTimeout(timer) // TODO: Remove this, it's just here for testing
Expand Down

0 comments on commit 8f7c5fc

Please sign in to comment.