mirror of
https://github.com/conduition/dlctix.git
synced 2026-01-30 05:05:06 +01:00
remove unused payout_value field from SplitSpendInfo
This commit is contained in:
@@ -78,7 +78,6 @@ pub(crate) fn build_split_txs(
|
||||
let split_spend_info = SplitSpendInfo::new(
|
||||
player,
|
||||
¶ms.market_maker,
|
||||
payout_value,
|
||||
params.relative_locktime_block_delta,
|
||||
)?;
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ use bitcoin::{
|
||||
sighash::{Prevouts, SighashCache},
|
||||
taproot::{LeafVersion, TapLeafHash, TaprootSpendInfo},
|
||||
transaction::InputWeightPrediction,
|
||||
Amount, ScriptBuf, TapSighashType, Transaction, TxOut, Witness,
|
||||
ScriptBuf, TapSighashType, Transaction, TxOut, Witness,
|
||||
};
|
||||
use musig2::{CompactSignature, KeyAggContext};
|
||||
use secp::{Point, Scalar};
|
||||
@@ -30,7 +30,6 @@ use crate::{
|
||||
#[derive(Clone)]
|
||||
pub(crate) struct SplitSpendInfo {
|
||||
tweaked_ctx: KeyAggContext,
|
||||
payout_value: Amount,
|
||||
spend_info: TaprootSpendInfo,
|
||||
win_script: ScriptBuf,
|
||||
reclaim_script: ScriptBuf,
|
||||
@@ -41,7 +40,6 @@ impl SplitSpendInfo {
|
||||
pub(crate) fn new(
|
||||
winner: &Player,
|
||||
market_maker: &MarketMaker,
|
||||
payout_value: Amount,
|
||||
block_delta: u16,
|
||||
) -> Result<SplitSpendInfo, Error> {
|
||||
let mut pubkeys = vec![market_maker.pubkey, winner.pubkey];
|
||||
@@ -116,7 +114,6 @@ impl SplitSpendInfo {
|
||||
|
||||
let split_spend_info = SplitSpendInfo {
|
||||
tweaked_ctx,
|
||||
payout_value,
|
||||
spend_info: tr_spend_info,
|
||||
win_script,
|
||||
reclaim_script,
|
||||
@@ -130,10 +127,6 @@ impl SplitSpendInfo {
|
||||
ScriptBuf::new_p2tr_tweaked(self.spend_info.output_key())
|
||||
}
|
||||
|
||||
pub(crate) fn payout_value(&self) -> Amount {
|
||||
self.payout_value
|
||||
}
|
||||
|
||||
/// Computes the input weight when spending an output of the split TX
|
||||
/// as an input of the player's win TX. This assumes the player's win script
|
||||
/// leaf is being used to unlock the taproot tree.
|
||||
|
||||
Reference in New Issue
Block a user