Skip to content

Commit

Permalink
Add extra data to event
Browse files Browse the repository at this point in the history
  • Loading branch information
Gauthamastro committed May 16, 2024
1 parent d05f1a0 commit f5dff60
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions pallets/xcm-helper/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ pub mod pallet {
__private::log,
};
use frame_system::pallet_prelude::*;
use thea_primitives::extras::extract_data_from_multilocation;
use thea_primitives::extras::{extract_data_from_multilocation, ExtraData};

use polkadex_primitives::Resolver;
use sp_core::{sp_std, H160};
Expand Down Expand Up @@ -265,8 +265,14 @@ pub mod pallet {
#[pallet::generate_deposit(pub(super) fn deposit_event)]
pub enum Event<T: Config> {
/// Asset Deposited from XCM
/// parameters. [id, recipient, multi-asset, asset_id]
AssetDeposited(H160, Box<MultiLocation>, Box<MultiAsset>, polkadex_primitives::AssetId),
/// parameters. [id, recipient, multi-asset, asset_id, extradata]
AssetDeposited(
H160,
Box<MultiLocation>,
Box<MultiAsset>,
polkadex_primitives::AssetId,
ExtraData,
),
/// Asset Withdraw using XCM
/// parameters. [id, asset_id]
AssetWithdrawn(H160, polkadex_primitives::AssetId),
Expand Down Expand Up @@ -424,6 +430,7 @@ pub mod pallet {
Box::new(*who),
Box::new(what.clone()),
asset_id,
extra,
));
Ok(())
}
Expand Down

0 comments on commit f5dff60

Please sign in to comment.