Skip to content

Commit ce524a2

Browse files
authored
Companion for: Substrate#13869 (#2631)
* Companion for: Substrate#13869 paritytech/substrate#13869 * Fix * Warning * update lockfile for {"polkadot", "substrate"} --------- Co-authored-by: parity-processbot <>
1 parent fa448da commit ce524a2

File tree

10 files changed

+275
-281
lines changed
  • cumulus
    • parachain-template/runtime/src
    • parachains/runtimes
  • system-parachains
    • bridge-hubs
    • collectives/collectives-polkadot/src

10 files changed

+275
-281
lines changed

Cargo.lock

Lines changed: 264 additions & 259 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

cumulus/parachain-template/runtime/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ impl pallet_balances::Config for Runtime {
340340
type WeightInfo = pallet_balances::weights::SubstrateWeight<Runtime>;
341341
type MaxReserves = ConstU32<50>;
342342
type ReserveIdentifier = [u8; 8];
343-
type HoldIdentifier = ();
343+
type RuntimeHoldReason = RuntimeHoldReason;
344344
type FreezeIdentifier = ();
345345
type MaxHolds = ConstU32<0>;
346346
type MaxFreezes = ConstU32<0>;

cumulus/parachains/runtimes/assets/statemine/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ impl pallet_balances::Config for Runtime {
205205
type WeightInfo = weights::pallet_balances::WeightInfo<Runtime>;
206206
type MaxReserves = ConstU32<50>;
207207
type ReserveIdentifier = [u8; 8];
208-
type HoldIdentifier = ();
208+
type RuntimeHoldReason = RuntimeHoldReason;
209209
type FreezeIdentifier = ();
210210
type MaxHolds = ConstU32<0>;
211211
type MaxFreezes = ConstU32<0>;

cumulus/parachains/runtimes/assets/statemint/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ impl pallet_balances::Config for Runtime {
220220
type WeightInfo = weights::pallet_balances::WeightInfo<Runtime>;
221221
type MaxReserves = ConstU32<50>;
222222
type ReserveIdentifier = [u8; 8];
223-
type HoldIdentifier = ();
223+
type RuntimeHoldReason = RuntimeHoldReason;
224224
type FreezeIdentifier = ();
225225
type MaxHolds = ConstU32<0>;
226226
type MaxFreezes = ConstU32<0>;

cumulus/parachains/runtimes/assets/westmint/src/lib.rs

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ use parachains_common::{
6868
Index, Signature, AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT,
6969
NORMAL_DISPATCH_RATIO, SLOT_DURATION,
7070
};
71-
use scale_info::TypeInfo;
7271
use xcm_config::{
7372
ForeignAssetsConvertedConcreteId, TrustBackedAssetsConvertedConcreteId, WestendLocation,
7473
XcmConfig, XcmOriginToTransactDispatchOrigin,
@@ -180,15 +179,6 @@ parameter_types! {
180179
pub const ExistentialDeposit: Balance = EXISTENTIAL_DEPOSIT;
181180
}
182181

183-
/// A reason for placing a hold on funds.
184-
#[derive(
185-
Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Encode, Decode, MaxEncodedLen, Debug, TypeInfo,
186-
)]
187-
pub enum HoldReason {
188-
/// Used by the NFT Fractionalization Pallet.
189-
NftFractionalization,
190-
}
191-
192182
impl pallet_balances::Config for Runtime {
193183
type MaxLocks = ConstU32<50>;
194184
/// The type for recording an account's balance.
@@ -201,7 +191,7 @@ impl pallet_balances::Config for Runtime {
201191
type WeightInfo = weights::pallet_balances::WeightInfo<Runtime>;
202192
type MaxReserves = ConstU32<50>;
203193
type ReserveIdentifier = [u8; 8];
204-
type HoldIdentifier = HoldReason;
194+
type RuntimeHoldReason = RuntimeHoldReason;
205195
type FreezeIdentifier = ();
206196
type MaxHolds = ConstU32<1>;
207197
type MaxFreezes = ConstU32<0>;
@@ -640,7 +630,6 @@ parameter_types! {
640630
pub const NftFractionalizationPalletId: PalletId = PalletId(*b"fraction");
641631
pub NewAssetSymbol: BoundedVec<u8, AssetsStringLimit> = (*b"FRAC").to_vec().try_into().unwrap();
642632
pub NewAssetName: BoundedVec<u8, AssetsStringLimit> = (*b"Frac").to_vec().try_into().unwrap();
643-
pub const NftFractionalizationHoldReason: HoldReason = HoldReason::NftFractionalization;
644633
}
645634

646635
impl pallet_nft_fractionalization::Config for Runtime {
@@ -658,7 +647,7 @@ impl pallet_nft_fractionalization::Config for Runtime {
658647
type Nfts = Nfts;
659648
type PalletId = NftFractionalizationPalletId;
660649
type WeightInfo = pallet_nft_fractionalization::weights::SubstrateWeight<Runtime>;
661-
type HoldReason = NftFractionalizationHoldReason;
650+
type RuntimeHoldReason = RuntimeHoldReason;
662651
#[cfg(feature = "runtime-benchmarks")]
663652
type BenchmarkHelper = ();
664653
}
@@ -747,7 +736,7 @@ construct_runtime!(
747736
Uniques: pallet_uniques::{Pallet, Call, Storage, Event<T>} = 51,
748737
Nfts: pallet_nfts::{Pallet, Call, Storage, Event<T>} = 52,
749738
ForeignAssets: pallet_assets::<Instance2>::{Pallet, Call, Storage, Event<T>} = 53,
750-
NftFractionalization: pallet_nft_fractionalization::{Pallet, Call, Storage, Event<T>} = 54,
739+
NftFractionalization: pallet_nft_fractionalization::{Pallet, Call, Storage, Event<T>, HoldReason} = 54,
751740
}
752741
);
753742

cumulus/parachains/runtimes/contracts/contracts-rococo/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ impl pallet_balances::Config for Runtime {
213213
type WeightInfo = pallet_balances::weights::SubstrateWeight<Runtime>;
214214
type MaxReserves = ConstU32<50>;
215215
type ReserveIdentifier = [u8; 8];
216-
type HoldIdentifier = ();
216+
type RuntimeHoldReason = RuntimeHoldReason;
217217
type FreezeIdentifier = ();
218218
type MaxHolds = ConstU32<0>;
219219
type MaxFreezes = ConstU32<0>;

system-parachains/bridge-hubs/bridge-hub-kusama/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ impl pallet_balances::Config for Runtime {
246246
type MaxLocks = ConstU32<50>;
247247
type MaxReserves = ConstU32<50>;
248248
type ReserveIdentifier = [u8; 8];
249-
type HoldIdentifier = ();
249+
type RuntimeHoldReason = RuntimeHoldReason;
250250
type FreezeIdentifier = ();
251251
type MaxHolds = ConstU32<0>;
252252
type MaxFreezes = ConstU32<0>;

system-parachains/bridge-hubs/bridge-hub-polkadot/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ impl pallet_balances::Config for Runtime {
246246
type MaxLocks = ConstU32<50>;
247247
type MaxReserves = ConstU32<50>;
248248
type ReserveIdentifier = [u8; 8];
249-
type HoldIdentifier = ();
249+
type RuntimeHoldReason = RuntimeHoldReason;
250250
type FreezeIdentifier = ();
251251
type MaxHolds = ConstU32<0>;
252252
type MaxFreezes = ConstU32<0>;

system-parachains/bridge-hubs/bridge-hub-rococo/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ impl pallet_balances::Config for Runtime {
261261
type MaxLocks = ConstU32<50>;
262262
type MaxReserves = ConstU32<50>;
263263
type ReserveIdentifier = [u8; 8];
264-
type HoldIdentifier = ();
264+
type RuntimeHoldReason = RuntimeHoldReason;
265265
type FreezeIdentifier = ();
266266
type MaxHolds = ConstU32<0>;
267267
type MaxFreezes = ConstU32<0>;

system-parachains/collectives/collectives-polkadot/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ impl pallet_balances::Config for Runtime {
208208
type WeightInfo = weights::pallet_balances::WeightInfo<Runtime>;
209209
type MaxReserves = ConstU32<50>;
210210
type ReserveIdentifier = [u8; 8];
211-
type HoldIdentifier = ();
211+
type RuntimeHoldReason = RuntimeHoldReason;
212212
type FreezeIdentifier = ();
213213
type MaxHolds = ConstU32<0>;
214214
type MaxFreezes = ConstU32<0>;

0 commit comments

Comments
 (0)