-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We do not want to expose the low-level function from chain handles(see `buildRedemptionData` from `EthereumBridge` handle). The goal of `src/ethereum.ts` is to translate domain-level objects into low-level Ethereum chain primitives and perform a call. Instead of having `buildRedemptionData` in `Bridge` interface here we modify the `approveAndCall` interface and replace `extraData: Hex` with domain-level objects, as accepted by `buildRedemptionData`. Here we also rename the `approveAndCall` to `requestRedemption` and explain in the docs it happens via `approveAndCall`- although `requestRedemption` does not exist on the Solidity code of TBTC token, having it in `TBTCToken` Typescript API is fine given we abstract the complexity and make the API human-readable.
- Loading branch information
1 parent
759cc78
commit 9249ee5
Showing
5 changed files
with
138 additions
and
142 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.