allow permanent unlock for internal sealing
This commit is contained in:
parent
0e5060db18
commit
a8b688b469
@ -212,7 +212,8 @@ pub struct Miner {
|
|||||||
sealing_block_last_request: Mutex<u64>,
|
sealing_block_last_request: Mutex<u64>,
|
||||||
// for sealing...
|
// for sealing...
|
||||||
options: MinerOptions,
|
options: MinerOptions,
|
||||||
seals_internally: bool,
|
/// Does the node perform internal (without work) sealing.
|
||||||
|
pub seals_internally: bool,
|
||||||
|
|
||||||
gas_range_target: RwLock<(U256, U256)>,
|
gas_range_target: RwLock<(U256, U256)>,
|
||||||
author: RwLock<Address>,
|
author: RwLock<Address>,
|
||||||
|
@ -190,7 +190,8 @@ pub fn setup_rpc<T: Extendable>(server: T, deps: Arc<Dependencies>, apis: ApiSet
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
Api::PersonalAccounts => {
|
Api::PersonalAccounts => {
|
||||||
server.add_delegate(PersonalAccountsClient::new(&deps.secret_store, &deps.client, &deps.miner, deps.geth_compatibility).to_delegate());
|
let enable_permanent_unlock = deps.geth_compatibility || deps.miner.seals_internally;
|
||||||
|
server.add_delegate(PersonalAccountsClient::new(&deps.secret_store, &deps.client, &deps.miner, enable_permanent_unlock).to_delegate());
|
||||||
},
|
},
|
||||||
Api::PersonalSafe => {
|
Api::PersonalSafe => {
|
||||||
server.add_delegate(PersonalClient::new(&deps.secret_store, &deps.client).to_delegate());
|
server.add_delegate(PersonalClient::new(&deps.secret_store, &deps.client).to_delegate());
|
||||||
|
Loading…
Reference in New Issue
Block a user