chore(rpc): add submit hashrate impl (#2153)

This commit is contained in:
Matthias Seitz
2023-04-08 10:25:18 +02:00
committed by GitHub
parent f3673c79f6
commit cf18edb0fe
3 changed files with 6 additions and 7 deletions

View File

@@ -209,6 +209,10 @@ pub trait EthApi {
async fn get_work(&self) -> Result<Work>;
/// Used for submitting mining hashrate.
///
/// Can be used for remote miners to submit their hash rate.
/// It accepts the miner hash rate and an identifier which must be unique between nodes.
/// Returns `true` if the block was successfully submitted, `false` otherwise.
#[method(name = "eth_submitHashrate")]
async fn submit_hashrate(&self, hashrate: U256, id: H256) -> Result<bool>;