Skip to content

Commit 449f319

Browse files
committed
Add let _: () = ... to rpc calls that return null
Two cases of rpcs that return null but were assigned to a variable `_` caused a lint error. Declare the variable as a unit type for the return value of rpcs that return null.
1 parent 1810527 commit 449f319

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

integration_test/tests/mining.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ fn submit_empty_block(node: &Node, bt: &mtype::GetBlockTemplate) {
150150
}
151151
}
152152

153-
let _ = node.client.submit_block(&block).expect("submitblock");
153+
let _: () = node.client.submit_block(&block).expect("submitblock");
154154
}
155155

156156
// FIXME: Submitting this block returns 'inconclusive'.
@@ -208,7 +208,7 @@ fn mining__submit_block_with_dummy_coinbase(node: &Node, bt: &mtype::GetBlockTem
208208
}
209209
}
210210

211-
let _ = node.client.submit_block(&block).expect("submitblock");
211+
let _: () = node.client.submit_block(&block).expect("submitblock");
212212
}
213213

214214
#[cfg(not(feature = "v17"))]

0 commit comments

Comments
 (0)