Skip to content

Instantly share code, notes, and snippets.

@jaybutera
Created February 20, 2021 03:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jaybutera/20fd6bbd2365080d9d089e7930254c8a to your computer and use it in GitHub Desktop.
Save jaybutera/20fd6bbd2365080d9d089e7930254c8a to your computer and use it in GitHub Desktop.
let xcm = Xcm::WithdrawAsset {
assets: vec![MultiAsset::ConcreteFungible {
id: Parent.into(),
amount: T::ToRelayChainBalance::convert(amount),
}],
effects: vec![Order::InitiateReserveWithdraw {
assets: vec![MultiAsset::All],
reserve: Parent.into(),
effects: vec![Order::DepositAsset {
assets: vec![MultiAsset::All],
dest: AccountId32 {
network: T::RelayChainNetworkId::get(),
id: T::AccountId32Convert::convert(dest.clone()),
}.into(),
}],
}],
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment