Skip to content

Commit 05c9a0c

Browse files
committed
Fixed formatting
1 parent a383b74 commit 05c9a0c

File tree

6 files changed

+10
-11
lines changed

6 files changed

+10
-11
lines changed

lightning-background-processor/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1432,7 +1432,7 @@ mod tests {
14321432
nodes[0].node.push_pending_event(Event::ProbeFailed {
14331433
payment_id: PaymentId([42; 32]),
14341434
payment_hash: PaymentHash([42; 32]),
1435-
path: path,
1435+
path,
14361436
short_channel_id: Some(scored_scid),
14371437
});
14381438
let event = receiver

lightning-block-sync/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,8 @@ impl<'a, C: Cache, L: Deref> ChainNotifier<'a, C, L> where L::Target: chain::Lis
410410
for header in connected_blocks.drain(..).rev() {
411411
let height = header.height;
412412
let block_data = chain_poller
413-
.fetch_block(&header).await.map_err(|e| (e, Some(new_tip)))?;
413+
.fetch_block(&header).await
414+
.map_err(|e| (e, Some(new_tip)))?;
414415
debug_assert_eq!(block_data.block_hash, header.block_hash);
415416

416417
match block_data.deref() {

lightning-block-sync/src/poll.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ impl Validate for BlockHeaderData {
6060

6161
fn validate(self, block_hash: BlockHash) -> BlockSourceResult<Self::T> {
6262
let pow_valid_block_hash = self.header
63-
.validate_pow(&self.header.target()).map_err(BlockSourceError::persistent)?;
63+
.validate_pow(&self.header.target())
64+
.map_err(BlockSourceError::persistent)?;
6465

6566
if pow_valid_block_hash != block_hash {
6667
return Err(BlockSourceError::persistent("invalid block hash"));
@@ -80,7 +81,8 @@ impl Validate for BlockData {
8081
};
8182

8283
let pow_valid_block_hash = header
83-
.validate_pow(&header.target()).map_err(BlockSourceError::persistent)?;
84+
.validate_pow(&header.target())
85+
.map_err(BlockSourceError::persistent)?;
8486

8587
if pow_valid_block_hash != block_hash {
8688
return Err(BlockSourceError::persistent("invalid block hash"));

lightning-invoice/src/de.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ use core::num::ParseIntError;
66
use core::str;
77
use core::str::FromStr;
88

9-
109
use bech32::{u5, FromBase32};
1110

1211
use bitcoin_hashes::Hash;
@@ -18,7 +17,6 @@ use lightning::routing::router::{RouteHint, RouteHintHop};
1817

1918
use num_traits::{CheckedAdd, CheckedMul};
2019

21-
2220
use secp256k1::ecdsa::{RecoveryId, RecoverableSignature};
2321
use secp256k1::PublicKey;
2422

lightning-invoice/src/utils.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -550,9 +550,9 @@ fn filter_channels<L: Deref>(
550550
}
551551

552552
if channel.is_usable && !online_channel_exists {
553-
log_trace!(logger, "Channel with connected peer exists for invoice route hints");
554-
online_channel_exists = true;
555-
}
553+
log_trace!(logger, "Channel with connected peer exists for invoice route hints");
554+
online_channel_exists = true;
555+
}
556556

557557
match filtered_channels.entry(channel.counterparty.node_id) {
558558
hash_map::Entry::Occupied(mut entry) => {

lightning-rapid-gossip-sync/src/lib.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -188,12 +188,10 @@ mod tests {
188188
test
189189
}
190190
fn get_test_directory(&self) -> String {
191-
192191
self.directory.clone() + "/graph-sync-tests"
193192
}
194193
fn get_test_file_path(&self) -> String {
195194
let graph_sync_test_directory = self.get_test_directory();
196-
197195
graph_sync_test_directory + "/test_data.lngossip"
198196
}
199197
}

0 commit comments

Comments
 (0)