Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions ddk-manager/src/contract/contract_input.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,10 @@ pub struct ContractInput {
impl ContractInput {
/// Validate the contract input parameters
pub fn validate(&self) -> Result<(), Error> {
if self.offer_collateral < DUST_LIMIT {
// Allow 0 collateral for single-funded DLCs, but non-zero must exceed dust limit
if self.offer_collateral > Amount::ZERO && self.offer_collateral < DUST_LIMIT {
return Err(Error::InvalidParameters(
"Offer collateral must be greater than dust limit.".to_string(),
"Non-zero offer collateral must be greater than dust limit.".to_string(),
));
}

Expand Down
Loading