Skip to content

Commit 9630e72

Browse files
committed
[pallet_identity] adapt paritytech/polkadot-sdk#2048
[pallet_identity] removed `FieldDeposit`, `MaxAdditionalFields`, added `ByteDeposit` fix import `simple` -> `legacy`
1 parent a4b1ca6 commit 9630e72

File tree

4 files changed

+20
-44
lines changed

4 files changed

+20
-44
lines changed

relay/kusama/src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ use frame_support::{
7878
};
7979
use frame_system::EnsureRoot;
8080
use pallet_grandpa::{fg_primitives, AuthorityId as GrandpaId};
81-
use pallet_identity::simple::IdentityInfo;
81+
use pallet_identity::legacy::IdentityInfo;
8282
use pallet_im_online::sr25519::AuthorityId as ImOnlineId;
8383
use pallet_session::historical as session_historical;
8484
use pallet_transaction_payment::{CurrencyAdapter, FeeDetails, RuntimeDispatchInfo};
@@ -920,7 +920,8 @@ impl claims::Config for Runtime {
920920
parameter_types! {
921921
// Minimum 100 bytes/KSM deposited (1 CENT/byte)
922922
pub const BasicDeposit: Balance = 1000 * CENTS; // 258 bytes on-chain
923-
pub const FieldDeposit: Balance = 250 * CENTS; // 66 bytes on-chain
923+
// TODO:(PR#137) - check ByteDeposit?
924+
pub const ByteDeposit: Balance = deposit(0, 1);
924925
pub const SubAccountDeposit: Balance = 200 * CENTS; // 53 bytes on-chain
925926
pub const MaxSubAccounts: u32 = 100;
926927
pub const MaxAdditionalFields: u32 = 100;
@@ -931,10 +932,9 @@ impl pallet_identity::Config for Runtime {
931932
type RuntimeEvent = RuntimeEvent;
932933
type Currency = Balances;
933934
type BasicDeposit = BasicDeposit;
934-
type FieldDeposit = FieldDeposit;
935+
type ByteDeposit = ByteDeposit;
935936
type SubAccountDeposit = SubAccountDeposit;
936937
type MaxSubAccounts = MaxSubAccounts;
937-
type MaxAdditionalFields = MaxAdditionalFields;
938938
type IdentityInformation = IdentityInfo<MaxAdditionalFields>;
939939
type MaxRegistrars = MaxRegistrars;
940940
type Slashed = Treasury;

relay/kusama/src/weights/pallet_identity.rs

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

relay/polkadot/src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ use frame_support::{
6666
};
6767
use frame_system::EnsureRoot;
6868
use pallet_grandpa::{fg_primitives, AuthorityId as GrandpaId};
69-
use pallet_identity::simple::IdentityInfo;
69+
use pallet_identity::legacy::IdentityInfo;
7070
use pallet_im_online::sr25519::AuthorityId as ImOnlineId;
7171
use pallet_session::historical as session_historical;
7272
use pallet_transaction_payment::{FeeDetails, RuntimeDispatchInfo};
@@ -795,7 +795,8 @@ impl pallet_fast_unstake::Config for Runtime {
795795
parameter_types! {
796796
// Minimum 4 CENTS/byte
797797
pub const BasicDeposit: Balance = deposit(1, 258);
798-
pub const FieldDeposit: Balance = deposit(0, 66);
798+
// TODO:(PR#137) - check ByteDeposit?
799+
pub const ByteDeposit: Balance = deposit(0, 1);
799800
pub const SubAccountDeposit: Balance = deposit(1, 53);
800801
pub const MaxSubAccounts: u32 = 100;
801802
pub const MaxAdditionalFields: u32 = 100;
@@ -806,10 +807,9 @@ impl pallet_identity::Config for Runtime {
806807
type RuntimeEvent = RuntimeEvent;
807808
type Currency = Balances;
808809
type BasicDeposit = BasicDeposit;
809-
type FieldDeposit = FieldDeposit;
810+
type ByteDeposit = ByteDeposit;
810811
type SubAccountDeposit = SubAccountDeposit;
811812
type MaxSubAccounts = MaxSubAccounts;
812-
type MaxAdditionalFields = MaxAdditionalFields;
813813
type IdentityInformation = IdentityInfo<MaxAdditionalFields>;
814814
type MaxRegistrars = MaxRegistrars;
815815
type Slashed = Treasury;

relay/polkadot/src/weights/pallet_identity.rs

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

0 commit comments

Comments
 (0)