mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 18:41:03 +00:00
Check out/in assets when teleporting to maintain total issuance (#3007)
* Check out/in assets when teleporting to maintain total issuance * Fixes * Fixes * Fixes * Fixes * Update xcm/xcm-executor/src/traits/transact_asset.rs Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com> * Docs Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
This commit is contained in:
@@ -26,6 +26,7 @@ use sp_runtime::{RuntimeDebug, traits::BadOrigin};
|
||||
use frame_support::traits::{EnsureOrigin, OriginTrait, Filter, Get, Contains};
|
||||
|
||||
pub use pallet::*;
|
||||
use frame_support::PalletId;
|
||||
|
||||
#[frame_support::pallet]
|
||||
pub mod pallet {
|
||||
@@ -33,6 +34,7 @@ pub mod pallet {
|
||||
use frame_support::pallet_prelude::*;
|
||||
use frame_system::pallet_prelude::*;
|
||||
use xcm_executor::traits::WeightBounds;
|
||||
use sp_runtime::traits::AccountIdConversion;
|
||||
|
||||
#[pallet::pallet]
|
||||
#[pallet::generate_store(pub(super) trait Store)]
|
||||
@@ -198,6 +200,11 @@ pub mod pallet {
|
||||
};
|
||||
T::XcmRouter::send_xcm(dest, message)
|
||||
}
|
||||
|
||||
pub fn check_account() -> T::AccountId {
|
||||
const ID: PalletId = PalletId(*b"py/xcmch");
|
||||
AccountIdConversion::<T::AccountId>::into_account(&ID)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user