File tree Expand file tree Collapse file tree 3 files changed +11
-10
lines changed
transactions/src/services Expand file tree Collapse file tree 3 files changed +11
-10
lines changed Original file line number Diff line number Diff line change @@ -159,8 +159,6 @@ impl TxAttributesType {
159159 . unwrap_or_default ( )
160160 . to_owned ( ) ;
161161
162- tracing:: error!( "{}" , timeout_timestamp) ;
163-
164162 Some ( Self :: SendPacket ( SendPacket {
165163 source_port,
166164 dest_port,
Original file line number Diff line number Diff line change @@ -311,6 +311,16 @@ impl InnerTransaction {
311311 pub fn was_successful ( & self ) -> bool {
312312 self . exit_code == TransactionExitStatus :: Applied
313313 }
314+
315+ pub fn is_ibc ( & self ) -> bool {
316+ matches ! (
317+ self . kind,
318+ TransactionKind :: IbcMsgTransfer ( _)
319+ | TransactionKind :: IbcTrasparentTransfer ( _)
320+ | TransactionKind :: IbcUnshieldingTransfer ( _)
321+ | TransactionKind :: IbcShieldingTransfer ( _)
322+ )
323+ }
314324}
315325
316326#[ derive( Debug , Clone ) ]
Original file line number Diff line number Diff line change @@ -15,14 +15,7 @@ pub fn get_ibc_packets(
1515 let mut ibc_txs = inner_txs
1616 . iter ( )
1717 . filter_map ( |tx| {
18- if matches ! (
19- tx. kind,
20- TransactionKind :: IbcMsgTransfer ( Some ( _) )
21- | TransactionKind :: IbcTrasparentTransfer ( _)
22- | TransactionKind :: IbcUnshieldingTransfer ( _)
23- | TransactionKind :: IbcShieldingTransfer ( _)
24- ) && tx. was_successful ( )
25- {
18+ if tx. is_ibc ( ) && tx. was_successful ( ) {
2619 Some ( tx. tx_id . clone ( ) )
2720 } else {
2821 None
You can’t perform that action at this time.
0 commit comments