Skip to content

Question: Is it possible to commit collateral from approved address A only when address B commits to buy? #5

Description

@chrishobcroft

So, right now, in order to open an order, you need to actually commit the collateral DAI to the contract.

Is it technically possible for the contract to only take _daiCollateralValue from the seller when the buyer commits _daiPaymentValue?

Obviously the transaction would fail if the seller hadn't approve the contract to spend at least _daiCollateralValue, or didn't have enough DAI to cover the _daiCollateralValue.

In a world where multiple sell orders could be placed by a single address, this would allow sellers to place a number of orders for different values / _deliveredByBlock - without actually needing to commit the DAI until a buyer takes one.

Obviously this complicates things slightly.

But my question is whether it's technically possible.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions