mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-17 06:35:42 +00:00
Simplify some Option / Result / ? operator patterns (#8653)
* Simplify some Option / Result / ? operator patterns When those match a combinator exactly. Tool-aided by [comby-rust](https://github.com/huitseeker/comby-rust). * adjust after review * adjust post-review
This commit is contained in:
committed by
GitHub
parent
541692c4a8
commit
052be8bbef
@@ -407,10 +407,7 @@ where
|
||||
);
|
||||
|
||||
// Check what happened after enaction of the verdict.
|
||||
let alive_contract_info = match new_contract_info.map_err(|_| IsTombstone)? {
|
||||
None => return Err(IsTombstone),
|
||||
Some(contract) => contract,
|
||||
};
|
||||
let alive_contract_info = new_contract_info.map_err(|_| IsTombstone)?.ok_or_else(|| IsTombstone)?;
|
||||
|
||||
// Compute how much would the fee per block be with the *updated* balance.
|
||||
let total_balance = T::Currency::total_balance(account);
|
||||
|
||||
Reference in New Issue
Block a user