git.delta.rocks / unique-network / refs/commits / be55c884f101

difftreelog

Merge pull request #1025 from UniqueNetwork/feature/disable-inflation

Yaroslav Bolyukin2023-10-24parents: #951758d #37fd570.patch.diff
in: master
Disable inflation for now

1 file changed

modifiedruntime/common/config/pallets/mod.rsdiffbeforeafterboth
111 type BlockNumber = BlockNumber;111 type BlockNumber = BlockNumber;
112112
113 fn current_block_number() -> Self::BlockNumber {113 fn current_block_number() -> Self::BlockNumber {
114 use hex_literal::hex;114 // This code was broken previously, but after fixing, we decided it would be better to leave it broken for now.
115 use parity_scale_codec::Decode;
116 use sp_io::storage;
117 // TODO: Replace with the following code after https://github.com/paritytech/polkadot-sdk/commit/3ea497b5a0fdda252f9c5a3c257cfaf8685f02fd lands
118 // <cumulus_pallet_parachain_system::Pallet<Runtime>>::last_relay_block_number()
119
120 // ParachainSystem.LastRelayChainBlockNumber
121 let Some(encoded) = storage::get(&hex!("45323df7cc47150b3930e2666b0aa313a2bca190d36bd834cc73a38fc213ecbd")) else {
122 // First parachain block
123 return Default::default()
124 };
125 BlockNumber::decode(&mut encoded.as_ref())115 0.into()
126 .expect("typeof(RelayBlockNumber) == typeof(BlockNumber) == u32; qed")116 // use hex_literal::hex;
117 // use parity_scale_codec::Decode;
118 // use sp_io::storage;
119 // // TODO: Replace with the following code after https://github.com/paritytech/polkadot-sdk/commit/3ea497b5a0fdda252f9c5a3c257cfaf8685f02fd lands
120 // // <cumulus_pallet_parachain_system::Pallet<Runtime>>::last_relay_block_number()
121 //
122 // // ParachainSystem.LastRelayChainBlockNumber
123 // let Some(encoded) = storage::get(&hex!("45323df7cc47150b3930e2666b0aa313a2bca190d36bd834cc73a38fc213ecbd")) else {
124 // // First parachain block
125 // return Default::default()
126 // };
127 // BlockNumber::decode(&mut encoded.as_ref())
128 // .expect("typeof(RelayBlockNumber) == typeof(BlockNumber) == u32; qed")
127 }129 }
128}130}
129131