X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Fchain%2Fchannelmonitor.rs;h=f63e4d12d55adc59fa1f81270aea9f669d03a65f;hb=refs%2Ftags%2Fv0.0.14;hp=f0b23c08619632c4ab14d45f5322d51cc017c38d;hpb=affefb677e3f9f1a586707484ac82b6c86f4f26b;p=rust-lightning diff --git a/lightning/src/chain/channelmonitor.rs b/lightning/src/chain/channelmonitor.rs index f0b23c08..f63e4d12 100644 --- a/lightning/src/chain/channelmonitor.rs +++ b/lightning/src/chain/channelmonitor.rs @@ -34,10 +34,11 @@ use bitcoin::secp256k1::{Secp256k1,Signature}; use bitcoin::secp256k1::key::{SecretKey,PublicKey}; use bitcoin::secp256k1; +use ln::{PaymentHash, PaymentPreimage}; use ln::msgs::DecodeError; use ln::chan_utils; use ln::chan_utils::{CounterpartyCommitmentSecrets, HTLCOutputInCommitment, HTLCType, ChannelTransactionParameters, HolderCommitmentTransaction}; -use ln::channelmanager::{BestBlock, HTLCSource, PaymentPreimage, PaymentHash}; +use ln::channelmanager::{BestBlock, HTLCSource}; use ln::onchaintx::{OnchainTxHandler, InputDescriptors}; use chain; use chain::WatchedOutput; @@ -2663,7 +2664,7 @@ impl ChannelMonitorImpl { /// transaction and losing money. This is a risk because previous channel states /// are toxic, so it's important that whatever channel state is persisted is /// kept up-to-date. -pub trait Persist: Send + Sync { +pub trait Persist { /// Persist a new channel's data. The data can be stored any way you want, but /// the identifier provided by Rust-Lightning is the channel's outpoint (and /// it is up to you to maintain a correct mapping between the outpoint and the @@ -3048,7 +3049,8 @@ mod tests { use hex; use chain::channelmonitor::ChannelMonitor; use chain::transaction::OutPoint; - use ln::channelmanager::{BestBlock, PaymentPreimage, PaymentHash}; + use ln::{PaymentPreimage, PaymentHash}; + use ln::channelmanager::BestBlock; use ln::onchaintx::{OnchainTxHandler, InputDescriptors}; use ln::chan_utils; use ln::chan_utils::{HTLCOutputInCommitment, ChannelPublicKeys, ChannelTransactionParameters, HolderCommitmentTransaction, CounterpartyChannelTransactionParameters};