Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.7.8 venus patch1 #389

Merged
merged 3 commits into from
Aug 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions pallets/storage-handler/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,8 @@ pub mod pallet {
OwnConsignment,
/// When casting a territory, it must be at least 30 days
BoundariesNotMet,
/// The redefined name is repeated and new_name cannot be used instead
DuplicateName,
}

#[pallet::storage]
Expand Down Expand Up @@ -779,6 +781,7 @@ pub mod pallet {
) -> DispatchResult {
let sender = ensure_signed(origin)?;
let territory = <Territory<T>>::try_get(&sender, &old_name).map_err(|_| Error::<T>::NotHaveTerritory)?;
ensure!(!<Territory<T>>::contains_key(&sender, &new_name), Error::<T>::DuplicateName);
ensure!(territory.state == TerritoryState::Active, Error::<T>::NotActive);
ensure!(territory.total_space == territory.remaining_space, Error::<T>::ObjectNotZero);
<Territory<T>>::remove(&sender, &old_name);
Expand Down
6 changes: 3 additions & 3 deletions standalone/chain/runtime/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
// and set impl_version to 0. If only runtime
// implementation changes and behavior does not, then leave spec_version as
// is and increment impl_version.
spec_version: 108,
spec_version: 115,
impl_version: 0,
apis: RUNTIME_API_VERSIONS,
transaction_version: 1,
Expand Down Expand Up @@ -432,7 +432,7 @@ impl pallet_balances::Config for Runtime {
}

parameter_types! {
pub const TransactionByteFee: Balance = 10 * MILLICENTS;
pub const TransactionByteFee: Balance = MILLICENTS;
pub const OperationalFeeMultiplier: u8 = 5;
pub const TargetBlockFullness: Perquintill = Perquintill::from_percent(25);
pub AdjustmentVariable: Multiplier = Multiplier::saturating_from_rational(1, 100_000);
Expand All @@ -444,7 +444,7 @@ impl pallet_transaction_payment::Config for Runtime {
type RuntimeEvent = RuntimeEvent;
type OnChargeTransaction = CurrencyAdapter<Balances, DealWithFees>;
type OperationalFeeMultiplier = OperationalFeeMultiplier;
type WeightToFee = IdentityFee<Balance>;
type WeightToFee = ConstantMultiplier<Balance, ConstU128<{ WEIGHT_FEE }>>;
type LengthToFee = ConstantMultiplier<Balance, TransactionByteFee>;
type FeeMultiplierUpdate =
TargetedFeeAdjustment<Self, TargetBlockFullness, AdjustmentVariable, MinimumMultiplier, MaximumMultiplier>;
Expand Down
Loading