mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-15 04:31:08 +00:00
Contracts add code_len to ContractsInfo (#14523)
* add code_len to v12 * fix * Update frame/contracts/src/wasm/mod.rs * fix * fixes * rm test * add test back * fix * update test * Fix comments * fix build * del * fix clippy * fix * re-rename
This commit is contained in:
@@ -80,6 +80,7 @@ pub struct CodeInfo<T: Config> {
|
||||
#[codec(compact)]
|
||||
refcount: u64,
|
||||
determinism: Determinism,
|
||||
code_len: u32,
|
||||
}
|
||||
|
||||
#[storage_alias]
|
||||
@@ -177,6 +178,7 @@ impl<T: Config> MigrationStep for Migration<T> {
|
||||
owner: old_info.owner,
|
||||
deposit,
|
||||
refcount: old_info.refcount,
|
||||
code_len: code_len as u32,
|
||||
};
|
||||
|
||||
let amount = old_info.deposit.saturating_sub(info.deposit);
|
||||
@@ -221,6 +223,7 @@ impl<T: Config> MigrationStep for Migration<T> {
|
||||
deposit: v.deposit,
|
||||
refcount: v.refcount,
|
||||
owner: v.owner,
|
||||
code_len: module.code.len() as u32,
|
||||
};
|
||||
(k, info)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user