pub fn do_asset_deposit(
			asset: &bridge::ResourceId,
			recipient: &T::AccountId,
			amount: BalanceOf<T>,
		) -> Option<BalanceOf<T>> {
			let bridge_id = <bridge::Pallet<T>>::account_id();
			let holding_balance = BridgeBalances::<T>::get(asset, &bridge_id).unwrap_or_default();
			let recipient_balance = BridgeBalances::<T>::get(asset, recipient).unwrap_or_default();

			BridgeBalances::<T>::insert(asset, &bridge_id, holding_balance.checked_sub(&amount)?);
			BridgeBalances::<T>::insert(asset, recipient, recipient_balance.checked_add(&amount)?);

			Some(amount)
		}
/// Deposit specific amount assets into recipient account.
///
/// Assets would be withdrawn from bridge account and then deposit to
/// recipient.
/// Bridge account is treat as holding account of all assets.
///
/// DO NOT guarantee asset was registered
/// DO NOT guarantee bridge account(e.g. hodling account) has enough balance
Deposit specific amount assets into recipient account.
Assets would be withdrawn from bridge account and then deposit to
recipient.
Bridge account is treat as holding account of all assets.

DO NOT guarantee asset was registered
DO NOT guarantee bridge account has enough balance
Deposit specific amount assets into recipient account . Assets would be withdrawn from bridge account and then deposit to recipient . Bridge account is treat as holding account of all assets . DO NOT guarantee asset was registered DO NOT guarantee bridge account has enough balance
pub fn do_asset_deposit(
			asset: &bridge::ResourceId,
			recipient: &T::AccountId,
			amount: BalanceOf<T>,
		) -> Option<BalanceOf<T>> {
			let bridge_id = <bridge::Pallet<T>>::account_id();
			let holding_balance = BridgeBalances::<T>::get(asset, &bridge_id).unwrap_or_default();
			let recipient_balance = BridgeBalances::<T>::get(asset, recipient).unwrap_or_default();
			BridgeBalances::<T>::insert(asset, &bridge_id, holding_balance.checked_sub(&amount)?);
			BridgeBalances::<T>::insert(asset, recipient, recipient_balance.checked_add(&amount)?);
			Some(amount)
		}
pub fn do_asset_deposit ( asset : & bridge :: ResourceId , recipient : & T :: AccountId , amount : BalanceOf < T > , ) -> Option < BalanceOf < T > > { let bridge_id = < bridge :: Pallet < T > > :: account_id ( ) ; let holding_balance = BridgeBalances :: < T > :: get ( asset , & bridge_id ) . unwrap_or_default ( ) ; let recipient_balance = BridgeBalances :: < T > :: get ( asset , recipient ) . unwrap_or_default ( ) ; BridgeBalances :: < T > :: insert ( asset , & bridge_id , holding_balance . checked_sub ( & amount ) ? ) ; BridgeBalances :: < T > :: insert ( asset , recipient , recipient_balance . checked_add ( & amount ) ? ) ; Some ( amount ) }
Deposit specific amount assets into recipient account.
Deposit specific amount assets into recipient account .
asset
&bridge::ResourceId
recipient
&T::AccountId
amount
BalanceOf<T>
asset
&bridge::ResourceId
recipient
&T::AccountId
amount
BalanceOf<T>